Hi, in the last refactoring (when applying the spatie package), it seems we don't need to define the Gate permission in the boot of the service provider anymore, because spatie already handles this for us, am I right?
For example:
When we use $this->authorize($permissionName), @can($permissionName)... in action, view. The spatie package will check whether the current user has $permissionName or not (via checking data in the spatie tables roles, permissions.... in database)
Thank you
PK
Povilas Korop
✓ Link copied!
This course was done a long time ago so I don't remember (or Spatie improved it), perhaps you're right.
Hi, in the last refactoring (when applying the spatie package), it seems we don't need to define the Gate permission in the boot of the service provider anymore, because spatie already handles this for us, am I right?
For example: When we use $this->authorize($permissionName), @can($permissionName)... in action, view. The spatie package will check whether the current user has $permissionName or not (via checking data in the spatie tables roles, permissions.... in database)
Thank you
This course was done a long time ago so I don't remember (or Spatie improved it), perhaps you're right.