entrust
entrust copied to clipboard
Update EntrustPermissionTrait.php
Summary of Improvements
- Added precise return types for roles() and boot method
- Renamed
boot()tobootEntrustPermissionTrait()to prevent trait conflicts - Replaced
sync([])withdetach()for better clarity and intent - Removed redundant
return truefrom model event listener - Cleaned up formatting and long lines
- Explicitly imported
BelongsToManyfor better readability
All changes are non-breaking and maintain the original behavior.