System.NullReferenceException on Empty String comparison

XMLWordPrintableJSON

    • Type: Bug
    • Resolution: Done
    • Priority: Major - P3
    • 1.6
    • Affects Version/s: 1.5
    • Component/s: None
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      The following code gives us a NullReferenceException in FirstOrDefault() implementation:

      collection.AsQueryable().Where(d => d.StringField == String.Empty).Select(d => d.SomeField).FirstOrDefault()

            Assignee:
            Robert Stam
            Reporter:
            Zaid Masud
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: