Completed
Push — master ( c02965...f19773 )
by Aleksandar
100:21 queued 75:50
created
packages/Category/src/Service/CategoryService.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -128,8 +128,7 @@
 block discarded – undo
128 128
         // We don't want to force user to re-upload image on edit
129 129
         if(!$values['main_img']) {
130 130
             unset($values['main_img']);
131
-        }
132
-        else{
131
+        } else{
133 132
             $this->upload->deleteFile($oldCategory->main_img);
134 133
         }
135 134
 
Please login to merge, or discard this patch.
packages/Article/src/Service/EventService.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -139,15 +139,13 @@
 block discarded – undo
139 139
         // We don't want to force user to re-upload image on edit
140 140
         if (!$event['featured_img']) {
141 141
             unset($event['featured_img']);
142
-        }
143
-        else {
142
+        } else {
144 143
             $this->upload->deleteFile($oldArticle->featured_img);
145 144
         }
146 145
 
147 146
         if (!$event['main_img']) {
148 147
             unset($event['main_img']);
149
-        }
150
-        else {
148
+        } else {
151 149
             $this->upload->deleteFile($oldArticle->main_img);
152 150
         }
153 151
 
Please login to merge, or discard this patch.
packages/Article/src/Service/PostService.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -146,15 +146,13 @@
 block discarded – undo
146 146
         // We don't want to force user to re-upload image on edit
147 147
         if (!$post['featured_img']) {
148 148
             unset($post['featured_img']);
149
-        }
150
-        else {
149
+        } else {
151 150
             $this->upload->deleteFile($oldArticle->featured_img);
152 151
         }
153 152
 
154 153
         if (!$post['main_img']) {
155 154
             unset($post['main_img']);
156
-        }
157
-        else {
155
+        } else {
158 156
             $this->upload->deleteFile($oldArticle->main_img);
159 157
         }
160 158
 
Please login to merge, or discard this patch.
packages/Article/src/Service/VideoService.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -158,15 +158,13 @@
 block discarded – undo
158 158
         // We don't want to force user to re-upload image on edit
159 159
         if(!$videos['featured_img']) {
160 160
             unset($videos['featured_img']);
161
-        }
162
-        else {
161
+        } else {
163 162
             $this->upload->deleteFile($oldArticle->featured_img);
164 163
         }
165 164
 
166 165
         if(!$videos['main_img']) {
167 166
             unset($videos['main_img']);
168
-        }
169
-        else {
167
+        } else {
170 168
             $this->upload->deleteFile($oldArticle->main_img);
171 169
         }
172 170
 
Please login to merge, or discard this patch.
packages/Menu/src/Controller/IndexController.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -84,17 +84,14 @@  discard block
 block discarded – undo
84 84
 
85 85
             if($id) {
86 86
                 $this->menuService->updateMenuItem($data, $id);
87
-            }
88
-            else{
87
+            } else{
89 88
                 $this->menuService->addMenuItem($data);
90 89
             }
91 90
 
92 91
             return $this->response->withStatus(302)->withHeader('Location', $this->router->generateUri('admin.menu'));
93
-        }
94
-        catch(FilterException $fe){
92
+        } catch(FilterException $fe){
95 93
             return $this->edit($fe->getArrayMessages());
96
-        }
97
-        catch(\Exception $e){
94
+        } catch(\Exception $e){
98 95
             throw $e;
99 96
         }
100 97
     }
@@ -106,8 +103,7 @@  discard block
 block discarded – undo
106 103
             $this->menuService->delete($id);
107 104
 
108 105
             return $this->response->withStatus(302)->withHeader('Location', $this->router->generateUri('admin.menu'));
109
-        }
110
-        catch(\Exception $e){
106
+        } catch(\Exception $e){
111 107
             throw $e;
112 108
         }
113 109
     }
Please login to merge, or discard this patch.
packages/Article/src/Controller/PostController.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -120,15 +120,12 @@  discard block
 block discarded – undo
120 120
 
121 121
             if($id) {
122 122
                 $this->postService->updateArticle($data, $id);
123
-            }
124
-            else{
123
+            } else{
125 124
                 $this->postService->createArticle($user, $data);
126 125
             }
127
-        }
128
-        catch(FilterException $fe){
126
+        } catch(FilterException $fe){
129 127
             return $this->edit($fe->getArrayMessages());
130
-        }
131
-        catch(\Exception $e){
128
+        } catch(\Exception $e){
132 129
             throw $e;
133 130
         }
134 131
 
@@ -145,8 +142,7 @@  discard block
 block discarded – undo
145 142
     {
146 143
         try{
147 144
             $this->postService->deleteArticle($this->request->getAttribute('id'));
148
-        }
149
-        catch(\Exception $e){
145
+        } catch(\Exception $e){
150 146
             throw $e;
151 147
         }
152 148
 
Please login to merge, or discard this patch.
packages/Category/src/Controller/IndexController.php 1 patch
Braces   +4 added lines, -8 removed lines patch added patch discarded remove patch
@@ -103,17 +103,14 @@  discard block
 block discarded – undo
103 103
 
104 104
             if($id) {
105 105
                 $this->categoryService->updateCategory($data, $id);
106
-            }
107
-            else{
106
+            } else{
108 107
                 $this->categoryService->createCategory($data);
109 108
             }
110 109
 
111 110
             return $this->response->withStatus(302)->withHeader('Location', $this->router->generateUri('admin.categories'));
112
-        }
113
-        catch(FilterException $fe){
111
+        } catch(FilterException $fe){
114 112
             return $this->edit($fe->getArrayMessages());
115
-        }
116
-        catch(\Exception $e){
113
+        } catch(\Exception $e){
117 114
             throw $e;
118 115
         }
119 116
     }
@@ -125,8 +122,7 @@  discard block
 block discarded – undo
125 122
             $this->categoryService->delete($id);
126 123
 
127 124
             return $this->response->withStatus(302)->withHeader('Location', $this->router->generateUri('admin.categories'));
128
-        }
129
-        catch(\Exception $e){
125
+        } catch(\Exception $e){
130 126
             return $this->response->withStatus(302)->withHeader('Location', $this->router->generateUri('admin.categories'));
131 127
         }
132 128
     }
Please login to merge, or discard this patch.
packages/Page/src/Service/PageService.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -104,8 +104,7 @@
 block discarded – undo
104 104
         // We don't want to force user to re-upload image on edit
105 105
         if(!$data['main_img']){
106 106
             unset($data['main_img']);
107
-        }
108
-        else{
107
+        } else{
109 108
             $this->upload->deleteFile($page->getMainImg());
110 109
         }
111 110
 
Please login to merge, or discard this patch.
packages/Admin/src/Service/AdminUserService.php 1 patch
Braces   +2 added lines, -4 removed lines patch added patch discarded remove patch
@@ -167,15 +167,13 @@
 block discarded – undo
167 167
         // We don't want to force user to re-upload image on edit
168 168
         if(!$data['face_img']) {
169 169
             unset($data['face_img']);
170
-        }
171
-        else{
170
+        } else{
172 171
             $this->upload->deleteFile($user->face_img);
173 172
         }
174 173
 
175 174
         if(!$data['profile_img']) {
176 175
             unset($data['profile_img']);
177
-        }
178
-        else{
176
+        } else{
179 177
             $this->upload->deleteFile($user->profile_img);
180 178
         }
181 179
 
Please login to merge, or discard this patch.