Passed
Push — master ( cc8463...0206ad )
by Mihail
09:28
created
Apps/View/Admin/default/user/user_delete.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@
 block discarded – undo
57 57
 <?php
58 58
     $form = new Form($model, ['class' => 'form-horizontal', 'method' => 'post', 'action' => '']);
59 59
     echo $form->start();
60
-    echo $form->submitButton(__('Delete'), ['class' => 'btn btn-danger']) . "&nbsp;";
60
+    echo $form->submitButton(__('Delete'), ['class' => 'btn btn-danger'])."&nbsp;";
61 61
     echo Url::link(['user/index'], __('Cancel'), ['class' => 'btn btn-default']);
62 62
     echo $form->finish();
63 63
 ?>
64 64
\ No newline at end of file
Please login to merge, or discard this patch.
Apps/Controller/Front/Feedback.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -41,18 +41,18 @@  discard block
 block discarded – undo
41 41
     {
42 42
         // get configs
43 43
         $configs = $this->getConfigs();
44
-        if (!App::$User->isAuth() && (int)$configs['guestAdd'] !== 1) {
44
+        if (!App::$User->isAuth() && (int) $configs['guestAdd'] !== 1) {
45 45
             throw new ForbiddenException(__('Feedback available only for authorized users'));
46 46
         }
47 47
 
48 48
         // initialize model
49
-        $model = new FormFeedbackAdd((int)$configs['useCaptcha'] === 1);
49
+        $model = new FormFeedbackAdd((int) $configs['useCaptcha'] === 1);
50 50
         if ($model->send()) {
51 51
             if ($model->validate()) {
52 52
                 // if validation is passed save data to db and get row
53 53
                 $record = $model->make();
54 54
                 App::$Session->getFlashBag()->add('success', __('Your message was added successful'));
55
-                $this->response->redirect('feedback/read/' . $record->id . '/' . $record->hash);
55
+                $this->response->redirect('feedback/read/'.$record->id.'/'.$record->hash);
56 56
             } else {
57 57
                 App::$Session->getFlashBag()->add('error', __('Message is not sended! Please, fix issues in form below'));
58 58
             }
@@ -61,7 +61,7 @@  discard block
 block discarded – undo
61 61
         // render output view
62 62
         return $this->view->render('create', [
63 63
             'model' => $model->filter(),
64
-            'useCaptcha' => (int)$configs['useCaptcha'] === 1
64
+            'useCaptcha' => (int) $configs['useCaptcha'] === 1
65 65
         ]);
66 66
     }
67 67
 
@@ -93,7 +93,7 @@  discard block
 block discarded – undo
93 93
         $userId = App::$User->isAuth() ? App::$User->identity()->getId() : 0;
94 94
         $model = null;
95 95
         // check if feedback post is not closed for answers
96
-        if ((int)$recordPost->closed === 0) {
96
+        if ((int) $recordPost->closed === 0) {
97 97
             // init new answer add model
98 98
             $model = new FormAnswerAdd($recordPost, $userId);
99 99
             // if answer is sender lets try to make it model
@@ -138,10 +138,10 @@  discard block
 block discarded – undo
138 138
         // check if action is submited
139 139
         if ($this->request->request->get('closeRequest', false)) {
140 140
             // if created by authorized user
141
-            if ((int)$record->user_id !== 0) {
141
+            if ((int) $record->user_id !== 0) {
142 142
                 $user = App::$User->identity();
143 143
                 // button is pressed not by request creator
144
-                if ($user === null || $user->getId() !== (int)$record->user_id) {
144
+                if ($user === null || $user->getId() !== (int) $record->user_id) {
145 145
                     throw new ForbiddenException(__('This feedback request was created by another user'));
146 146
                 }
147 147
             }
@@ -152,7 +152,7 @@  discard block
 block discarded – undo
152 152
 
153 153
             // add notification and redirect
154 154
             App::$Session->getFlashBag()->add('warning', __('Feedback request now is closed!'));
155
-            $this->response->redirect('feedback/read/' . $id . '/' . $hash);
155
+            $this->response->redirect('feedback/read/'.$id.'/'.$hash);
156 156
         }
157 157
 
158 158
         return $this->view->render('close');
@@ -168,7 +168,7 @@  discard block
 block discarded – undo
168 168
     public function actionList()
169 169
     {
170 170
         // set current page and offset
171
-        $page = (int)$this->request->query->get('page');
171
+        $page = (int) $this->request->query->get('page');
172 172
         $offset = $page * self::ITEM_PER_PAGE;
173 173
 
174 174
         // check if user is authorized or throw exception
Please login to merge, or discard this patch.
Apps/Controller/Front/Profile.php 1 patch
Spacing   +20 added lines, -20 removed lines patch added patch discarded remove patch
@@ -52,9 +52,9 @@  discard block
 block discarded – undo
52 52
         $records = null;
53 53
 
54 54
         // set current page and offset
55
-        $page = (int)$this->request->query->get('page', 0);
55
+        $page = (int) $this->request->query->get('page', 0);
56 56
         $cfgs = Serialize::decode($this->application->configs);
57
-        $userPerPage = (int)$cfgs['usersOnPage'];
57
+        $userPerPage = (int) $cfgs['usersOnPage'];
58 58
         if ($userPerPage < 1) {
59 59
             $userPerPage = 1;
60 60
         }
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
         switch ($filter_name) {
64 64
             case 'rating': // rating list, order by rating DESC
65 65
                 // check if rating is enabled
66
-                if ((int)$cfgs['rating'] !== 1) {
66
+                if ((int) $cfgs['rating'] !== 1) {
67 67
                     throw new NotFoundException();
68 68
                 }
69 69
                 $records = (new ProfileRecords())->orderBy('rating', 'DESC');
@@ -72,7 +72,7 @@  discard block
 block discarded – undo
72 72
                 if (Str::likeEmpty($filter_value)) {
73 73
                     throw new NotFoundException();
74 74
                 }
75
-                $records = (new ProfileRecords())->where('hobby', 'like', '%' . $filter_value . '%');
75
+                $records = (new ProfileRecords())->where('hobby', 'like', '%'.$filter_value.'%');
76 76
                 break;
77 77
             case 'city':
78 78
                 if (Str::likeEmpty($filter_value)) {
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
                 if ($filter_value === null || !Obj::isLikeInt($filter_value)) {
85 85
                     throw new NotFoundException();
86 86
                 }
87
-                $records = (new ProfileRecords())->where('birthday', 'like', $filter_value . '-%');
87
+                $records = (new ProfileRecords())->where('birthday', 'like', $filter_value.'-%');
88 88
                 break;
89 89
             case 'all':
90 90
                 $records = (new ProfileRecords())->orderBy('id', 'DESC');
@@ -107,7 +107,7 @@  discard block
 block discarded – undo
107 107
             'pagination' => $pagination,
108 108
             'id' => $filter_name,
109 109
             'add' => $filter_value,
110
-            'ratingOn' => (int)$cfgs['rating']
110
+            'ratingOn' => (int) $cfgs['rating']
111 111
         ]);
112 112
     }
113 113
 
@@ -123,7 +123,7 @@  discard block
 block discarded – undo
123 123
     public function actionShow($userId)
124 124
     {
125 125
         $cfg = Serialize::decode($this->application->configs);
126
-        if ((int)$cfg['guestView'] !== 1 && !App::$User->isAuth()) {
126
+        if ((int) $cfg['guestView'] !== 1 && !App::$User->isAuth()) {
127 127
             throw new ForbiddenException(__('You must login to view other profile'));
128 128
         }
129 129
         // check if target exists
@@ -145,7 +145,7 @@  discard block
 block discarded – undo
145 145
                     App::$Session->getFlashBag()->add('error', __('This user are in your black list or you are in blacklist!'));
146 146
                 } else {
147 147
                     // check if message added
148
-                    if ($wallModel->makePost($targetPersone, $viewerPersone, (int)$cfg['delayBetweenPost'])) {
148
+                    if ($wallModel->makePost($targetPersone, $viewerPersone, (int) $cfg['delayBetweenPost'])) {
149 149
                         App::$Session->getFlashBag()->add('success', __('The message was successful posted!'));
150 150
                     } else {
151 151
                         App::$Session->getFlashBag()->add('warning', __('Posting message was failed! Please, wait few seconds'));
@@ -156,8 +156,8 @@  discard block
 block discarded – undo
156 156
 
157 157
         $query = $targetPersone->getWall(); // relation hasMany from users to walls
158 158
         // pagination and query params
159
-        $wallPage = (int)$this->request->query->get('page');
160
-        $wallItems = (int)$cfg['wallPostOnPage'];
159
+        $wallPage = (int) $this->request->query->get('page');
160
+        $wallItems = (int) $cfg['wallPostOnPage'];
161 161
         $wallOffset = $wallPage * $wallItems;
162 162
 
163 163
         // build pagination
@@ -179,7 +179,7 @@  discard block
 block discarded – undo
179 179
             'notify' => App::$Session->getFlashBag()->all(),
180 180
             'wallRecords' => $wallRecords,
181 181
             'pagination' => $wallPagination,
182
-            'ratingOn' => (int)$cfg['rating'] === 1
182
+            'ratingOn' => (int) $cfg['rating'] === 1
183 183
         ]);
184 184
     }
185 185
 
@@ -251,7 +251,7 @@  discard block
 block discarded – undo
251 251
         $wallModel = new FormWallPostDelete($wallPost);
252 252
         if ($wallModel->send() && $wallModel->validate()) {
253 253
             $wallModel->make();
254
-            $this->response->redirect('profile/show/' . $wallPost->target_id);
254
+            $this->response->redirect('profile/show/'.$wallPost->target_id);
255 255
         }
256 256
 
257 257
         return $this->view->render('wall_delete', [
@@ -291,7 +291,7 @@  discard block
 block discarded – undo
291 291
         }
292 292
 
293 293
         // get page index and current user object
294
-        $page = (int)$this->request->query->get('page', 0);
294
+        $page = (int) $this->request->query->get('page', 0);
295 295
         $offset = $page * static::NOTIFY_PER_PAGE;
296 296
         $user = App::$User->identity();
297 297
 
@@ -404,7 +404,7 @@  discard block
 block discarded – undo
404 404
 
405 405
         // set user id from ?id= get param if form not sended
406 406
         if (!$model->send()) {
407
-            $uid = (int)$this->request->query->get('id');
407
+            $uid = (int) $this->request->query->get('id');
408 408
             if ($uid > 0) {
409 409
                 $model->id = $uid;
410 410
             }
@@ -422,7 +422,7 @@  discard block
 block discarded – undo
422 422
         // get blocked users
423 423
         $records = Blacklist::where('user_id', '=', $user->getId());
424 424
 
425
-        $page = (int)$this->request->query->get('page');
425
+        $page = (int) $this->request->query->get('page');
426 426
         $offset = $page * self::BLOCK_PER_PAGE;
427 427
 
428 428
         // build pagination
@@ -527,9 +527,9 @@  discard block
 block discarded – undo
527 527
         // check if request is sended
528 528
         if ($model->send() && $model->validate()) {
529 529
             // get records from db
530
-            $records = ProfileRecords::where('nick', 'like', '%' . $model->query . '%');
531
-            $page = (int)$this->request->query->get('page');
532
-            $userPerPage = (int)$cfgs['usersOnPage'];
530
+            $records = ProfileRecords::where('nick', 'like', '%'.$model->query.'%');
531
+            $page = (int) $this->request->query->get('page');
532
+            $userPerPage = (int) $cfgs['usersOnPage'];
533 533
             if ($userPerPage < 1) {
534 534
                 $userPerPage = 1;
535 535
             }
@@ -551,7 +551,7 @@  discard block
 block discarded – undo
551 551
             'model' => $model->filter(),
552 552
             'records' => $records,
553 553
             'pagination' => $pagination,
554
-            'ratingOn' => (int)$cfgs['rating']
554
+            'ratingOn' => (int) $cfgs['rating']
555 555
         ]);
556 556
     }
557 557
 
@@ -575,7 +575,7 @@  discard block
 block discarded – undo
575 575
         // build sitemap from content items via business model
576 576
         $sitemap = new EntityBuildMap($langs);
577 577
         foreach ($profiles->get() as $user) {
578
-            $sitemap->add('profile/show/' . $user->user_id, $user->updated_at, 'weekly', 0.2);
578
+            $sitemap->add('profile/show/'.$user->user_id, $user->updated_at, 'weekly', 0.2);
579 579
         }
580 580
 
581 581
         $sitemap->save('profile');
Please login to merge, or discard this patch.
Apps/Controller/Front/Search.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -25,14 +25,14 @@
 block discarded – undo
25 25
     public function actionIndex()
26 26
     {
27 27
         // get search query value from GET headers
28
-        $query = (string)$this->request->query->get('query', null);
28
+        $query = (string) $this->request->query->get('query', null);
29 29
         // strip html tags
30 30
         $query = App::$Security->strip_tags($query);
31 31
         // get configs
32 32
         $configs = $this->getConfigs();
33 33
 
34 34
         // check search query length
35
-        if (Str::likeEmpty($query) || Str::length($query) < (int)$configs['minLength']) {
35
+        if (Str::likeEmpty($query) || Str::length($query) < (int) $configs['minLength']) {
36 36
             throw new NotFoundException(__('Search query is too short!'));
37 37
         }
38 38
 
Please login to merge, or discard this patch.
Apps/Controller/Api/Profile.php 1 patch
Spacing   +13 added lines, -13 removed lines patch added patch discarded remove patch
@@ -160,7 +160,7 @@  discard block
 block discarded – undo
160 160
             $answerTime = Date::convertToTimestamp($lastAnswer->created_at);
161 161
             $cfgs = \Apps\ActiveRecord\App::getConfigs('app', 'Profile');
162 162
             // hmm, maybe past less then delay required?
163
-            if ($now - (int)$cfgs['delayBetweenPost'] < $answerTime) {
163
+            if ($now - (int) $cfgs['delayBetweenPost'] < $answerTime) {
164 164
                 throw new ForbiddenException('Delay between answers not pass');
165 165
             }
166 166
         }
@@ -175,7 +175,7 @@  discard block
 block discarded – undo
175 175
         // add notification for target user
176 176
         if ($viewer->id !== $target_id) {
177 177
             $notify = new EntityAddNotification($target_id);
178
-            $notify->add('/profile/show/' . $target_id . '#wall-post-' . $wallRow->id, EntityAddNotification::MSG_ADD_WALLANSWER, [
178
+            $notify->add('/profile/show/'.$target_id.'#wall-post-'.$wallRow->id, EntityAddNotification::MSG_ADD_WALLANSWER, [
179 179
                 'snippet' => Text::snippet($message, 50),
180 180
                 'post' => $wallRow->message
181 181
             ]);
@@ -219,7 +219,7 @@  discard block
 block discarded – undo
219 219
         $postInfo = $findAnswer->getWallPost();
220 220
 
221 221
         // if not a target user of answer and not answer owner - lets throw exception
222
-        if($postInfo->target_id !== $viewer->id && $findAnswer->user_id !== $viewer->id) {
222
+        if ($postInfo->target_id !== $viewer->id && $findAnswer->user_id !== $viewer->id) {
223 223
             throw new ForbiddenException('Access declined!');
224 224
         }
225 225
 
@@ -280,7 +280,7 @@  discard block
 block discarded – undo
280 280
             // sender is not myself? then i'm - target (remote user is sender user->to_me)
281 281
             if ($row->sender_id !== $user->id) {
282 282
                 $userList[] = $row->sender_id;
283
-                if ((int)$row->tread === 0) {
283
+                if ((int) $row->tread === 0) {
284 284
                     $unreadList[] = $row->sender_id;
285 285
                 }
286 286
             }
@@ -360,7 +360,7 @@  discard block
 block discarded – undo
360 360
 
361 361
         // get special types for this action
362 362
         $queryType = $this->request->get('type');
363
-        $queryId = (int)$this->request->get('id');
363
+        $queryId = (int) $this->request->get('id');
364 364
         // get current user object
365 365
         $user = App::$User->identity();
366 366
 
@@ -376,11 +376,11 @@  discard block
 block discarded – undo
376 376
         switch ($queryType) {
377 377
             case 'after':
378 378
                 $messages = Message::where('id', '>', $queryId)
379
-                    ->where(function ($query) use ($cor_id, $user) {
380
-                        $query->where(function ($q) use ($cor_id, $user){
379
+                    ->where(function($query) use ($cor_id, $user) {
380
+                        $query->where(function($q) use ($cor_id, $user){
381 381
                             $q->where('target_id', '=', $user->getId())
382 382
                                 ->where('sender_id', '=', $cor_id);
383
-                        })->orWhere(function ($q) use ($cor_id, $user){
383
+                        })->orWhere(function($q) use ($cor_id, $user){
384 384
                             $q->where('target_id', '=', $cor_id)
385 385
                                 ->where('sender_id', '=', $user->getId());
386 386
                         });
@@ -388,11 +388,11 @@  discard block
 block discarded – undo
388 388
                 break;
389 389
             case 'before':
390 390
                 $messages = Message::where('id', '<', $queryId)
391
-                    ->where(function ($query) use ($cor_id, $user) {
392
-                        $query->where(function ($q) use ($cor_id, $user){
391
+                    ->where(function($query) use ($cor_id, $user) {
392
+                        $query->where(function($q) use ($cor_id, $user){
393 393
                             $q->where('target_id', '=', $user->getId())
394 394
                                 ->where('sender_id', '=', $cor_id);
395
-                        })->orWhere(function ($q) use ($cor_id, $user){
395
+                        })->orWhere(function($q) use ($cor_id, $user){
396 396
                             $q->where('target_id', '=', $cor_id)
397 397
                                 ->where('sender_id', '=', $user->getId());
398 398
                         });
@@ -500,7 +500,7 @@  discard block
 block discarded – undo
500 500
         $this->setJsonHeader();
501 501
 
502 502
         // get operation type and target user id
503
-        $target_id = (int)$this->request->get('target');
503
+        $target_id = (int) $this->request->get('target');
504 504
         $type = $this->request->get('type');
505 505
 
506 506
         // check type of query
@@ -515,7 +515,7 @@  discard block
 block discarded – undo
515 515
 
516 516
         $cfg = \Apps\ActiveRecord\App::getConfigs('app', 'Profile');
517 517
         // check if rating is enabled for website
518
-        if ((int)$cfg['rating'] !== 1) {
518
+        if ((int) $cfg['rating'] !== 1) {
519 519
             throw new NativeException('Rating is disabled');
520 520
         }
521 521
 
Please login to merge, or discard this patch.
Apps/Controller/Api/Comments.php 1 patch
Spacing   +10 added lines, -10 removed lines patch added patch discarded remove patch
@@ -32,7 +32,7 @@  discard block
 block discarded – undo
32 32
         $this->setJsonHeader();
33 33
         $configs = AppRecord::getConfigs('widget', 'Comments');
34 34
 
35
-        $replayTo = (int)$this->request->request->get('replay-to');
35
+        $replayTo = (int) $this->request->request->get('replay-to');
36 36
         $model = null;
37 37
         // check if its a answer (comment answer type)
38 38
         if ($replayTo > 0) {
@@ -44,7 +44,7 @@  discard block
 block discarded – undo
44 44
         }
45 45
 
46 46
         // pass general comment params to model
47
-        $model->message = App::$Security->secureHtml((string)$this->request->request->get('message'));
47
+        $model->message = App::$Security->secureHtml((string) $this->request->request->get('message'));
48 48
         $model->guestName = App::$Security->strip_tags($this->request->request->get('guest-name'));
49 49
 
50 50
         // check model conditions before add new row
@@ -76,12 +76,12 @@  discard block
 block discarded – undo
76 76
         // get configs
77 77
         $configs = AppRecord::getConfigs('widget', 'Comments');
78 78
         // items per page
79
-        $perPage = (int)$configs['perPage'];
79
+        $perPage = (int) $configs['perPage'];
80 80
         // offset can be only integer
81
-        $index = (int)$index;
81
+        $index = (int) $index;
82 82
         $offset = $perPage * $index;
83 83
         // get comment target path and check
84
-        $path = (string)$this->request->query->get('path');
84
+        $path = (string) $this->request->query->get('path');
85 85
         if (Str::likeEmpty($path)) {
86 86
             throw new NotFoundException('Wrong path');
87 87
         }
@@ -91,7 +91,7 @@  discard block
 block discarded – undo
91 91
             ->where('moderate', '=', 0);
92 92
 
93 93
         // check if comments is depend of language locale
94
-        if ((int)$configs['onlyLocale'] === 1) {
94
+        if ((int) $configs['onlyLocale'] === 1) {
95 95
             $query = $query->where('lang', '=', $this->request->getLanguage());
96 96
         }
97 97
 
@@ -141,7 +141,7 @@  discard block
 block discarded – undo
141 141
     {
142 142
         $this->setJsonHeader();
143 143
         // check input data
144
-        if (!Obj::isLikeInt($commentId) || (int)$commentId < 1) {
144
+        if (!Obj::isLikeInt($commentId) || (int) $commentId < 1) {
145 145
             throw new ForbiddenException('Input data is incorrect');
146 146
         }
147 147
 
@@ -151,7 +151,7 @@  discard block
 block discarded – undo
151 151
         // get data from db by comment id
152 152
         $records = CommentAnswer::where('comment_id', '=', $commentId)
153 153
             ->where('moderate', '=', 0);
154
-        if ((int)$configs['onlyLocale'] === 1) {
154
+        if ((int) $configs['onlyLocale'] === 1) {
155 155
             $records = $records->where('lang', '=', $this->request->getLanguage());
156 156
         }
157 157
 
@@ -195,11 +195,11 @@  discard block
 block discarded – undo
195 195
         foreach ($path as $id => $uri) {
196 196
             $query = CommentPost::where('pathway', '=', $uri)->where('moderate', '=', 0);
197 197
             // check if comments is depend of language locale
198
-            if ((int)$configs['onlyLocale'] === 1) {
198
+            if ((int) $configs['onlyLocale'] === 1) {
199 199
                 $query = $query->where('lang', '=', $this->request->getLanguage());
200 200
             }
201 201
             // set itemId => count
202
-            $count[(int)$id] = $query->count();
202
+            $count[(int) $id] = $query->count();
203 203
         }
204 204
         // render json response
205 205
         return json_encode(['status' => 1, 'count' => $count]);
Please login to merge, or discard this patch.
Apps/Controller/Admin/Feedback.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
     public function actionIndex()
34 34
     {
35 35
         // set current page and offset
36
-        $page = (int)$this->request->query->get('page');
36
+        $page = (int) $this->request->query->get('page');
37 37
         $offset = $page * self::ITEM_PER_PAGE;
38 38
 
39 39
         // get feedback posts AR table
@@ -75,7 +75,7 @@  discard block
 block discarded – undo
75 75
 
76 76
         // initialize model with answer add if thread is not closed
77 77
         $model = null;
78
-        if ((int)$record->closed !== 1) {
78
+        if ((int) $record->closed !== 1) {
79 79
             $model = new FormAnswerAdd($record, App::$User->identity()->getId());
80 80
             if ($model->send()) {
81 81
                 if ($model->validate()) {
@@ -115,7 +115,7 @@  discard block
 block discarded – undo
115 115
             case 'answer':
116 116
                 $record = FeedbackAnswer::find($id);
117 117
                 if ($record !== null && $record !== false) {
118
-                    $postId = (int)$record->getFeedbackPost()->id;
118
+                    $postId = (int) $record->getFeedbackPost()->id;
119 119
                 }
120 120
                 break;
121 121
         }
@@ -131,7 +131,7 @@  discard block
 block discarded – undo
131 131
             if ($model->validate()) {
132 132
                 $model->make();
133 133
                 App::$Session->getFlashBag()->add('success', __('Feedback item are successful changed'));
134
-                $this->response->redirect('feedback/read/' . $postId);
134
+                $this->response->redirect('feedback/read/'.$postId);
135 135
             } else {
136 136
                 App::$Session->getFlashBag()->add('danger', __('Updating is failed'));
137 137
             }
@@ -181,7 +181,7 @@  discard block
 block discarded – undo
181 181
         App::$Session->getFlashBag()->add('success', __('Feedback request is changed!'));
182 182
 
183 183
         // redirect to feedback post read
184
-        $this->response->redirect('feedback/read/' . $id);
184
+        $this->response->redirect('feedback/read/'.$id);
185 185
         return null;
186 186
     }
187 187
 
@@ -226,7 +226,7 @@  discard block
 block discarded – undo
226 226
                 // its a answer, lets remove it and redirect back in post
227 227
                 $postId = $record->feedback_id;
228 228
                 $record->delete();
229
-                $this->response->redirect('feedback/read/' . $postId);
229
+                $this->response->redirect('feedback/read/'.$postId);
230 230
             }
231 231
         }
232 232
 
Please login to merge, or discard this patch.
Apps/Controller/Admin/User.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -40,7 +40,7 @@  discard block
 block discarded – undo
40 40
         $query = new UserRecords();
41 41
 
42 42
         // set current page and offset
43
-        $page = (int)$this->request->query->get('page', 0);
43
+        $page = (int) $this->request->query->get('page', 0);
44 44
         $offset = $page * self::ITEM_PER_PAGE;
45 45
 
46 46
         // build pagination
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
     public function actionDelete($id = null)
105 105
     {
106 106
         // check if id is passed or get data from GET as array ids
107
-        if ($id === 0 || (int)$id < 1) {
107
+        if ($id === 0 || (int) $id < 1) {
108 108
             $ids = $this->request->query->get('selected');
109 109
             if (Obj::isArray($ids) && Arr::onlyNumericValues($ids)) {
110 110
                 $id = $ids;
Please login to merge, or discard this patch.
Apps/Controller/Admin/Profile.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -33,7 +33,7 @@  discard block
 block discarded – undo
33 33
         $query = new ProfileRecords();
34 34
 
35 35
         // set current page and offset
36
-        $page = (int)$this->request->query->get('page');
36
+        $page = (int) $this->request->query->get('page');
37 37
         $offset = $page * self::ITEM_PER_PAGE;
38 38
 
39 39
         // build pagination
@@ -60,7 +60,7 @@  discard block
 block discarded – undo
60 60
      */
61 61
     public function actionDelete($id)
62 62
     {
63
-        $this->response->redirect('user/delete/' . $id);
63
+        $this->response->redirect('user/delete/'.$id);
64 64
     }
65 65
 
66 66
     /**
Please login to merge, or discard this patch.