I have an extension method called ParseItemsToIntegers
which is an extension method of an array of strings, and I'm using it like any extension would be used.
var ids = ChkBoxSelected.ParseItemsToIntegers();
The behavior I've observed is that, if ChkBoxSelected
is null, it will call the extension method without a problem, but then in side the extension method it throws a null reference exception on the null string array.
How was it able to resolve the extension method on the null?
Why did it not throw a null reference exception on ChkBoxSelected
when I called the extension method?