Skip to content

ThenBy(named_parameter) without OrderBy throws NullReferenceException instead of InvalidOperationException #278

Closed
hmobius opened this Issue Apr 10, 2013 · 0 comments

1 participant

@hmobius
hmobius commented Apr 10, 2013

If I call ThenBy() over a base command without a call to OrderBy(), I'd expect an InvalidOperationException to be thrown. This is true if I call.

db.Albums.All().ThenBy();
db.Albums.All().ThenByArtistId();

But if I call the named parameter version I get a NullReferenceException.

db.Albums.All().ThenBy(db.Albums.ArtistId);

Am guessing it should also throw an InvalidOperationException.

@markrendle markrendle added a commit that closed this issue May 21, 2013
@markrendle Fixes #278 506125b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.