-
-
Notifications
You must be signed in to change notification settings - Fork 468
If I have a schema like:
type Mutation {
updatePosts(input: [UpdatePostInput!]!): [Posts!]! @updateMany @can?
}
Is there mechanism in the canQuery or canFind directives that would allow checking policy on each model?
All reactions
Answered by
k0ka
Jul 22, 2025
Both canFind and canQuery can do it. We even have tests for it:
public function testHandleMultipleModels(): void
public function testHandleMultipleModelsWithQuery(): void
Replies: 1 comment
Both canFind and canQuery can do it. We even have tests for it:
public function testHandleMultipleModels(): void
public function testHandleMultipleModelsWithQuery(): void
All reactions
-
👍 1
0 replies
Answer selected by
k0ka
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment