DirectoryTree / Authorization

Easy, native Laravel user authorization.
MIT License
162 stars 7 forks source link

Update Authorizable.php #11

Closed mkinyua53 closed 4 months ago

mkinyua53 commented 4 months ago

Ensure that permissions are actually retrieved from the cache if it (cache) is not disabled.

The current method of calling $this->permissions would run a query against the database regardless of whether the cache was set or not.

This pull request fixes that by running the find against the Collection in cache.

stevebauman commented 4 months ago

Thanks for the PR @mkinyua53! Tests are all failing however