GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Branch master (2980c2)
by Andrea
04:14
created
src/app/Http/Controllers/RolesController.php 2 patches
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -6,7 +6,6 @@
 block discarded – undo
6 6
 use Afrittella\BackProject\Http\Requests\RoleEdit;
7 7
 use Afrittella\BackProject\Repositories\Permissions;
8 8
 use Afrittella\BackProject\Repositories\Roles;
9
-use Illuminate\Http\Request;
10 9
 use Prologue\Alerts\Facades\Alert;
11 10
 
12 11
 class RolesController extends Controller
Please login to merge, or discard this patch.
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -37,12 +37,12 @@
 block discarded – undo
37 37
 
38 38
     public function create(Permissions $permissions)
39 39
     {
40
-        return view('back-project::roles.create')->with('permissions',  $permissions->all());
40
+        return view('back-project::roles.create')->with('permissions', $permissions->all());
41 41
     }
42 42
 
43 43
     public function store(RoleAdd $request, Roles $roles)
44 44
     {
45
-        $role= $roles->create($request->all());
45
+        $role = $roles->create($request->all());
46 46
 
47 47
         Alert::add('success', trans('back-project::crud.model_created', ['model' => trans('back-project::roles.role')]))->flash();
48 48
 
Please login to merge, or discard this patch.
src/app/Http/Controllers/UsersController.php 1 patch
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -3,13 +3,11 @@
 block discarded – undo
3 3
 namespace Afrittella\BackProject\Http\Controllers;
4 4
 
5 5
 use Afrittella\BackProject\Http\Requests\AccountStore;
6
-use Afrittella\BackProject\Http\Requests\AccountEdit;
7 6
 use Afrittella\BackProject\Repositories\Users;
8 7
 use Afrittella\BackProject\Repositories\Roles;
9 8
 use Afrittella\BackProject\Http\Requests\UserAdd;
10 9
 use Afrittella\BackProject\Http\Requests\UserEdit;
11 10
 use Afrittella\BackProject\Events\UserRegistered as Registered;
12
-use Illuminate\Http\Request;
13 11
 use Prologue\Alerts\Facades\Alert;
14 12
 use Auth;
15 13
 
Please login to merge, or discard this patch.
src/app/Listeners/SendRegistrationEmail.php 2 patches
Unused Use Statements   -3 removed lines patch added patch discarded remove patch
@@ -3,11 +3,8 @@
 block discarded – undo
3 3
 namespace Afrittella\BackProject\Listeners;
4 4
 
5 5
 use Afrittella\BackProject\Events\UserRegistered;
6
-use Illuminate\Queue\InteractsWithQueue;
7 6
 use Illuminate\Contracts\Queue\ShouldQueue;
8
-
9 7
 use Afrittella\BackProject\Repositories\Users;
10
-
11 8
 use Illuminate\Support\Facades\Log;
12 9
 use Afrittella\BackProject\Notifications\RegistrationEmail;
13 10
 
Please login to merge, or discard this patch.
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -32,12 +32,12 @@
 block discarded – undo
32 32
      */
33 33
     public function handle(UserRegistered $event)
34 34
     {
35
-      //try {
35
+        //try {
36 36
         $user = $this->users->findBy('id', $event->user_id);
37 37
         $user->notify(new RegistrationEmail($user));
38
-      //} catch(\Exception $e) {
38
+        //} catch(\Exception $e) {
39 39
         //Log::error('lavoro fallito');
40
-      //}
40
+        //}
41 41
 
42 42
     }
43 43
 
Please login to merge, or discard this patch.
src/app/Listeners/SendRegistrationEmailNoQueue.php 2 patches
Unused Use Statements   -4 removed lines patch added patch discarded remove patch
@@ -3,11 +3,7 @@
 block discarded – undo
3 3
 namespace Afrittella\BackProject\Listeners;
4 4
 
5 5
 use Afrittella\BackProject\Events\UserRegistered;
6
-use Illuminate\Queue\InteractsWithQueue;
7
-use Illuminate\Contracts\Queue\ShouldQueue;
8
-
9 6
 use Afrittella\BackProject\Repositories\Users;
10
-
11 7
 use Illuminate\Support\Facades\Log;
12 8
 use Afrittella\BackProject\Notifications\RegistrationEmail;
13 9
 
Please login to merge, or discard this patch.
Indentation   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,12 +31,12 @@
 block discarded – undo
31 31
      */
32 32
     public function handle(UserRegistered $event)
33 33
     {
34
-      //try {
34
+        //try {
35 35
         $user = $this->users->findBy('id', $event->user_id);
36 36
         $user->notify(new RegistrationEmail($user));
37
-      //} catch(\Exception $e) {
37
+        //} catch(\Exception $e) {
38 38
         //Log::error('lavoro fallito');
39
-      //}
39
+        //}
40 40
 
41 41
     }
42 42
 
Please login to merge, or discard this patch.
src/app/Notifications/RegistrationEmail.php 2 patches
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -27,7 +27,7 @@
 block discarded – undo
27 27
      * Get the notification's delivery channels.
28 28
      *
29 29
      * @param  mixed  $notifiable
30
-     * @return array
30
+     * @return string[]
31 31
      */
32 32
     public function via($notifiable)
33 33
     {
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -4,7 +4,6 @@
 block discarded – undo
4 4
 
5 5
 use Illuminate\Bus\Queueable;
6 6
 use Illuminate\Notifications\Notification;
7
-use Illuminate\Contracts\Queue\ShouldQueue;
8 7
 use Illuminate\Notifications\Messages\MailMessage;
9 8
 
10 9
 class RegistrationEmail extends Notification
Please login to merge, or discard this patch.
src/app/Repositories/Base.php 4 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -96,6 +96,9 @@
 block discarded – undo
96 96
         return $this->model->findOrCreate($data);
97 97
     }
98 98
 
99
+    /**
100
+     * @param string $attribute
101
+     */
99 102
     public function findBy($attribute, $value, $columns = array('*'))
100 103
     {
101 104
         $this->applyCriteria();
Please login to merge, or discard this patch.
Unused Use Statements   -1 removed lines patch added patch discarded remove patch
@@ -7,7 +7,6 @@
 block discarded – undo
7 7
 use Afrittella\BackProject\Exceptions\NotSavedException;
8 8
 use Afrittella\BackProject\Exceptions\RepositoryException;
9 9
 use Afrittella\BackProject\Repositories\Criteria\Criteria;
10
-use Illuminate\Container\Container as App;
11 10
 use Illuminate\Database\Eloquent\Model;
12 11
 use Illuminate\Support\Collection;
13 12
 
Please login to merge, or discard this patch.
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -48,7 +48,7 @@  discard block
 block discarded – undo
48 48
         return $this->model->create($data);
49 49
     }
50 50
 
51
-    public function update(array $data, $id, $attribute="id")
51
+    public function update(array $data, $id, $attribute = "id")
52 52
     {
53 53
         $model_data = $this->model->where($attribute, '=', $id)->first();
54 54
 
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
         return $this;
124 124
     }
125 125
 
126
-    public function skipCriteria($status = true){
126
+    public function skipCriteria($status = true) {
127 127
         $this->skipCriteria = $status;
128 128
         return $this;
129 129
     }
@@ -143,11 +143,11 @@  discard block
 block discarded – undo
143 143
     }
144 144
 
145 145
     public function  applyCriteria() {
146
-        if($this->skipCriteria === true)
146
+        if ($this->skipCriteria === true)
147 147
             return $this;
148 148
 
149
-        foreach($this->getCriteria() as $criteria) {
150
-            if($criteria instanceof Criteria)
149
+        foreach ($this->getCriteria() as $criteria) {
150
+            if ($criteria instanceof Criteria)
151 151
                 $this->model = $criteria->apply($this->model, $this);
152 152
         }
153 153
 
Please login to merge, or discard this patch.
Braces   +9 added lines, -6 removed lines patch added patch discarded remove patch
@@ -107,8 +107,9 @@  discard block
 block discarded – undo
107 107
         //$model = $this->app->make($this->model());
108 108
         $model = app()->make($this->model());
109 109
 
110
-        if (!$model instanceof Model)
111
-            throw new RepositoryException("Class {$this->model()} must be an instance of Illuminate\\Database\\Eloquent\\Model");
110
+        if (!$model instanceof Model) {
111
+                    throw new RepositoryException("Class {$this->model()} must be an instance of Illuminate\\Database\\Eloquent\\Model");
112
+        }
112 113
 
113 114
         return $this->model = $model;
114 115
     }
@@ -143,12 +144,14 @@  discard block
 block discarded – undo
143 144
     }
144 145
 
145 146
     public function  applyCriteria() {
146
-        if($this->skipCriteria === true)
147
-            return $this;
147
+        if($this->skipCriteria === true) {
148
+                    return $this;
149
+        }
148 150
 
149 151
         foreach($this->getCriteria() as $criteria) {
150
-            if($criteria instanceof Criteria)
151
-                $this->model = $criteria->apply($this->model, $this);
152
+            if($criteria instanceof Criteria) {
153
+                            $this->model = $criteria->apply($this->model, $this);
154
+            }
152 155
         }
153 156
 
154 157
         return $this;
Please login to merge, or discard this patch.
src/app/Repositories/Criteria/Attachments/ByUser.php 1 patch
Unused Use Statements   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 namespace Afrittella\BackProject\Repositories\Criteria\Attachments;
3 3
 
4 4
 use Afrittella\BackProject\Repositories\Criteria\Criteria;
5
-use Afrittella\BackProject\Contracts\BaseRepository as  Repository;
5
+use Afrittella\BackProject\Contracts\BaseRepository as Repository;
6 6
 use Illuminate\Support\Facades\Auth;
7 7
 
8 8
 class ByUser extends Criteria {
Please login to merge, or discard this patch.
src/app/Repositories/Criteria/ByUser.php 1 patch
Unused Use Statements   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -2,7 +2,7 @@
 block discarded – undo
2 2
 namespace Afrittella\BackProject\Repositories\Criteria;
3 3
 
4 4
 use Afrittella\BackProject\Repositories\Criteria\Criteria;
5
-use Afrittella\BackProject\Contracts\BaseRepository as  Repository;
5
+use Afrittella\BackProject\Contracts\BaseRepository as Repository;
6 6
 use Illuminate\Support\Facades\Auth;
7 7
 
8 8
 class ByUser extends Criteria {
Please login to merge, or discard this patch.
src/app/Repositories/Menus.php 3 patches
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -26,6 +26,9 @@
 block discarded – undo
26 26
         return $this->model->withDepth()->find($id, $columns);
27 27
     }
28 28
 
29
+    /**
30
+     * @param string $name
31
+     */
29 32
     public function tree($name)
30 33
     {
31 34
         $root = $this->findBy('name', $name);
Please login to merge, or discard this patch.
Unused Use Statements   -2 removed lines patch added patch discarded remove patch
@@ -1,8 +1,6 @@
 block discarded – undo
1 1
 <?php
2 2
 namespace Afrittella\BackProject\Repositories;
3 3
 
4
-use Afrittella\BackProject\Contracts\BaseRepository;
5
-
6 4
 class Menus extends Base
7 5
 {
8 6
     function model()
Please login to merge, or discard this patch.
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
         $body = [];
71 71
 
72 72
         foreach ($data as $row):
73
-            $actions =[
73
+            $actions = [
74 74
                 'edit' => ['url' => route('menus.edit', [$row->id])]
75 75
             ];
76 76
 
Please login to merge, or discard this patch.