-
Notifications
You must be signed in to change notification settings - Fork 11.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
prevent policies from being too greedy
- return `false` on `resolvePolicyCallback` if the ability/method is not callable - if no policy callback is found, allow the gate to try and resolve the ability before defaulting to `false`. - add test to make sure policies defer to the gate if method does not exist on policy - minor rename to other test to explicitly state the policy defaults to false if the method does not exists **AND** the gate does not exist.
- Loading branch information
Showing
2 changed files
with
23 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters