@@ -39,7 +39,7 @@ discard block |
||
39 | 39 | * Revokes the given permission from the role. |
40 | 40 | * |
41 | 41 | * @param int|null $permissionId |
42 | - * @return bool |
|
42 | + * @return integer |
|
43 | 43 | */ |
44 | 44 | public function revokePermission($permissionId = null) |
45 | 45 | { |
@@ -60,7 +60,7 @@ discard block |
||
60 | 60 | /** |
61 | 61 | * Revokes all permissions from the role. |
62 | 62 | * |
63 | - * @return bool |
|
63 | + * @return integer |
|
64 | 64 | */ |
65 | 65 | public function revokeAllPermissions() |
66 | 66 | { |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | * Attach a role to user using slug. |
104 | 104 | * |
105 | 105 | * @param $slug |
106 | - * @return bool |
|
106 | + * @return null|false |
|
107 | 107 | */ |
108 | 108 | public function attachRoleBySlug($slug) |
109 | 109 | { |
@@ -116,7 +116,7 @@ discard block |
||
116 | 116 | * Attach a role to user |
117 | 117 | * |
118 | 118 | * @param Role $role |
119 | - * @return boolean |
|
119 | + * @return null|false |
|
120 | 120 | */ |
121 | 121 | public function attachRole(Role $role) |
122 | 122 | { |
@@ -127,7 +127,7 @@ discard block |
||
127 | 127 | * Assigns the given role to the user. |
128 | 128 | * |
129 | 129 | * @param int $roleId |
130 | - * @return bool |
|
130 | + * @return null|false |
|
131 | 131 | */ |
132 | 132 | public function assignRole($roleId = null) |
133 | 133 | { |
@@ -171,7 +171,7 @@ discard block |
||
171 | 171 | * Revokes the given role from the user using slug. |
172 | 172 | * |
173 | 173 | * @param string $slug |
174 | - * @return bool |
|
174 | + * @return integer |
|
175 | 175 | */ |
176 | 176 | public function revokeRoleBySlug($slug) |
177 | 177 | { |
@@ -184,7 +184,7 @@ discard block |
||
184 | 184 | * Revokes the given role from the user. |
185 | 185 | * |
186 | 186 | * @param mixed $role |
187 | - * @return bool |
|
187 | + * @return integer |
|
188 | 188 | */ |
189 | 189 | public function revokeRole($role = "") |
190 | 190 | { |
@@ -205,7 +205,7 @@ discard block |
||
205 | 205 | /** |
206 | 206 | * Revokes all roles from the user. |
207 | 207 | * |
208 | - * @return bool |
|
208 | + * @return integer |
|
209 | 209 | */ |
210 | 210 | public function revokeAllRoles() |
211 | 211 | { |
@@ -2,8 +2,8 @@ |
||
2 | 2 | |
3 | 3 | namespace Yajra\Acl\Traits; |
4 | 4 | |
5 | -use Yajra\Acl\Models\Role; |
|
6 | 5 | use Illuminate\Support\Str; |
6 | +use Yajra\Acl\Models\Role; |
|
7 | 7 | |
8 | 8 | trait HasRole |
9 | 9 | { |
@@ -4,8 +4,6 @@ |
||
4 | 4 | |
5 | 5 | use Illuminate\Foundation\Support\Providers\AuthServiceProvider as ServiceProvider; |
6 | 6 | use Illuminate\View\Compilers\BladeCompiler; |
7 | -use Yajra\Acl\Models\Permission; |
|
8 | -use Yajra\Acl\Models\Role; |
|
9 | 7 | |
10 | 8 | class AclServiceProvider extends ServiceProvider |
11 | 9 | { |
@@ -2,11 +2,11 @@ |
||
2 | 2 | |
3 | 3 | namespace Yajra\Acl; |
4 | 4 | |
5 | +use Illuminate\Contracts\Auth\Access\Gate as GateContract; |
|
6 | +use Illuminate\Contracts\Cache\Repository; |
|
7 | +use Illuminate\Support\Collection; |
|
5 | 8 | use Illuminate\Support\Str; |
6 | 9 | use Yajra\Acl\Models\Permission; |
7 | -use Illuminate\Support\Collection; |
|
8 | -use Illuminate\Contracts\Cache\Repository; |
|
9 | -use Illuminate\Contracts\Auth\Access\Gate as GateContract; |
|
10 | 10 | |
11 | 11 | class GateRegistrar |
12 | 12 | { |