Passed
Pull Request — master (#14)
by ARCANEDEV
06:41
created
src/Core/Http/Routes/DashboardRoutes.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -24,7 +24,7 @@
 block discarded – undo
24 24
      */
25 25
     public function map(): void
26 26
     {
27
-        $this->adminGroup(function () {
27
+        $this->adminGroup(function() {
28 28
             // admin::index
29 29
             $this->get('/', [DashboardController::class, 'index'])
30 30
                  ->name('index');
Please login to merge, or discard this patch.
src/Core/CoreServiceProvider.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -63,7 +63,7 @@
 block discarded – undo
63 63
      */
64 64
     private function extendMetricsAuthorization(): void
65 65
     {
66
-        Metric::macro('authorizedToSee', function (Request $request): bool {
66
+        Metric::macro('authorizedToSee', function(Request $request): bool {
67 67
             return method_exists($this, 'authorize')
68 68
                 ? $this->authorize($request) === true
69 69
                 : true;
Please login to merge, or discard this patch.
src/Core/ViewComposers/NotificationsComposer.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -60,7 +60,7 @@
 block discarded – undo
60 60
     {
61 61
         $view->with(
62 62
             'foundationNotifications',
63
-            $this->notifier->notifications()->transform(function (array $notification) {
63
+            $this->notifier->notifications()->transform(function(array $notification) {
64 64
                 return static::prepareNotification($notification);
65 65
             })
66 66
         );
Please login to merge, or discard this patch.
src/Core/ViewComposers/MetricsComposer.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -62,10 +62,10 @@
 block discarded – undo
62 62
     public function compose(View $view): void
63 63
     {
64 64
         $metrics = $this->manager->makeSelected()
65
-            ->filter(function ($metric) {
65
+            ->filter(function($metric) {
66 66
                 return $metric->authorizedToSee(request());
67 67
             })
68
-            ->transform(function (Metric $metric) {
68
+            ->transform(function(Metric $metric) {
69 69
                 return Element::withTag("{$metric->type()}-metric")->attribute(':metric', $metric->toJson());
70 70
             });
71 71
 
Please login to merge, or discard this patch.
src/Auth/Metrics/Roles/TotalUsersByRoles.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@
 block discarded – undo
32 32
     public function calculate(Request $request, RolesRepository $repo)
33 33
     {
34 34
         // Calculate roles with users count
35
-        $result = $repo->withCount(['users'])->get()->filter(function ($role) {
35
+        $result = $repo->withCount(['users'])->get()->filter(function($role) {
36 36
             return $role->users_count > 0;
37 37
         })->pluck('users_count', 'name');
38 38
 
Please login to merge, or discard this patch.
src/Auth/Console/MakeUser.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -73,7 +73,7 @@
 block discarded – undo
73 73
      */
74 74
     protected static function defaultCreateUserCallback(): Closure
75 75
     {
76
-        return function (string $firstName, string $lastName, string $email, string $password, bool $isAdmin) {
76
+        return function(string $firstName, string $lastName, string $email, string $password, bool $isAdmin) {
77 77
             /** @var  \Arcanesoft\Foundation\Auth\Repositories\UsersRepository  $repo */
78 78
             $repo = app(UsersRepository::class);
79 79
             $now  = Date::now();
Please login to merge, or discard this patch.
src/Auth/Models/Role.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -398,7 +398,7 @@  discard block
 block discarded – undo
398 398
         if ( ! $this->isActive())
399 399
             return false;
400 400
 
401
-        return $this->permissions->filter(function (Permission $permission) use ($ability) {
401
+        return $this->permissions->filter(function(Permission $permission) use ($ability) {
402 402
             return $permission->hasAbility($ability);
403 403
         })->first() !== null;
404 404
     }
@@ -415,7 +415,7 @@  discard block
 block discarded – undo
415 415
     {
416 416
         $permissions = is_array($permissions) ? collect($permissions) : $permissions;
417 417
 
418
-        $failed = $permissions->reject(function ($permission) {
418
+        $failed = $permissions->reject(function($permission) {
419 419
             return $this->can($permission);
420 420
         })->values();
421 421
 
Please login to merge, or discard this patch.
src/Auth/Models/PermissionsGroup.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -311,7 +311,7 @@
 block discarded – undo
311 311
         $this->loadPermissions();
312 312
 
313 313
         return $this->permissions
314
-            ->filter(function (Permission $permission) use ($id) {
314
+            ->filter(function(Permission $permission) use ($id) {
315 315
                 return $permission->getKey() == $id;
316 316
             })
317 317
             ->first();
Please login to merge, or discard this patch.
src/Auth/Models/Presenters/PermissionPresenter.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
      */
31 31
     public function getUsersCountAttribute(): int
32 32
     {
33
-        return $this->roles->sum(function (Role $role) {
33
+        return $this->roles->sum(function(Role $role) {
34 34
             return $role->users->count();
35 35
         });
36 36
     }
Please login to merge, or discard this patch.