refactor: code style changes
Signed-off-by: miguel456 <me@nogueira.codes>
This commit is contained in:
@@ -18,13 +18,13 @@ class ApiKeyPolicy
|
||||
*/
|
||||
public function viewAny(User $user)
|
||||
{
|
||||
if ($user->hasRole('admin'))
|
||||
if ($user->hasRole('admin')) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Determine whether the user can create models.
|
||||
*
|
||||
@@ -33,8 +33,9 @@ class ApiKeyPolicy
|
||||
*/
|
||||
public function create(User $user)
|
||||
{
|
||||
if ($user->hasRole('admin'))
|
||||
if ($user->hasRole('admin')) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
@@ -48,8 +49,9 @@ class ApiKeyPolicy
|
||||
*/
|
||||
public function update(User $user, ApiKey $apiKey)
|
||||
{
|
||||
if ($user->hasRole('admin'))
|
||||
if ($user->hasRole('admin')) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
@@ -63,10 +65,10 @@ class ApiKeyPolicy
|
||||
*/
|
||||
public function delete(User $user, ApiKey $apiKey)
|
||||
{
|
||||
if ($user->hasRole('admin'))
|
||||
if ($user->hasRole('admin')) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user