Skip to content
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

Queries for __typename fail #56

Closed
hayes opened this issue Dec 20, 2021 · 1 comment · Fixed by #57
Closed

Queries for __typename fail #56

hayes opened this issue Dec 20, 2021 · 1 comment · Fixed by #57

Comments

@hayes
Copy link
Contributor

hayes commented Dec 20, 2021

When using wrapExecuteFn queries that contain __typename will fail with an error Cannot read property 'args' of undefined.

This comes from https://github.com/AstrumU/graphql-authz/blob/main/packages/core/src/rules-compiler.ts#L285-L287

the __typename field is not actually a field in the graphql schema, so certain operations (like trying to get the field schema, or fetch args for it) will not work.

@dimatill
Copy link
Contributor

@hayes thank you for opening the issue! 🙏 Would you like to create PR for fixing this?

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

Successfully merging a pull request may close this issue.

2 participants