-
Notifications
You must be signed in to change notification settings - Fork 97
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
Security attribute on extended type #653
Comments
Hmm, well, for starters, a muation class would typically be in your "controller" layer and isn't a "type" per se. I'm not really sure why you'd do this. Have you tried extending the |
Well, the controller looks like this
And we wanted to use But as far as you say above and from example I see here https://graphqlite.thecodingmachine.io/docs/extend-type the Well it worked well until I had to add #[Security] attribute there and seems there are some related issues here too |
I'm still failing to see the value in using the |
OK, ignore it then, as I said it worked well and it was nice way to split long type classes, but I can create extra controllers for them and use as separate type. Thanks, feel free to close, but still it looks like there is a bug with method |
I just read back over your examples again and noticed that you're calling your classes Mutations, but then annotating them as types. I don't understand this naming/design choice and that's the root of my confusion. You might want to rethink that. A mutation is a field, not a type. To call a class WhateverMutation is really misleading. I was assuming those were controllers for the actual mutations. I see the issue now, the |
I am getting error when trying to use Security attribute on extended type class.
I have mutation class
Then I have extended class, with Security attribute usage
Which gives me error
here
graphqlite/src/Middlewares/SecurityFieldMiddleware.php
Line 118 in b63eaec
Version: v5.0.3
The text was updated successfully, but these errors were encountered: