Skip to content

Crashes in QueryParser #210

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
shuebner opened this issue Dec 15, 2017 · 0 comments
Closed

Crashes in QueryParser #210

shuebner opened this issue Dec 15, 2017 · 0 comments
Labels
Milestone

Comments

@shuebner
Copy link

There are some errors in the QueryParser that make it throw unexpected exceptions:

  1. ParseFieldsQuery throws NullReferenceException when the field in the query doesn't exist, because of unchecked SingleOrDefault() (same thing in ContextGraph.GetRelationshipName btw)

  2. Page query parsing crashes with some malformed queries, e. g. ParsePageQuery will crash when querying with ?page[size]=a. This should probably be a TryParse instead of a ToInt32

I can prepare a PR if you want.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

2 participants