Passed
Push — master ( c86e8c...1b1f16 )
by Mihail
04:54
created
Loader/Admin/index.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@
 block discarded – undo
10 10
 define('env_no_uri', false);
11 11
 define('env_type', 'html');
12 12
 
13
-require_once(root . '/Loader/Autoload.php');
13
+require_once(root.'/Loader/Autoload.php');
14 14
 
15 15
 // make fast-access alias \App::$Object
16 16
 // class_alias('Ffcms\Core\App', 'App');
Please login to merge, or discard this patch.
Loader/Front/index.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -10,7 +10,7 @@
 block discarded – undo
10 10
 define('env_no_uri', true);
11 11
 define('env_type', 'html');
12 12
 
13
-require_once(root . '/Loader/Autoload.php');
13
+require_once(root.'/Loader/Autoload.php');
14 14
 
15 15
 // make fast-access alias \App::$Object
16 16
 // class_alias('Ffcms\Core\App', 'App');
Please login to merge, or discard this patch.
Loader/Api/index.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
 // this environment is based on json response type
13 13
 define('env_type', 'json');
14 14
 
15
-require_once(root . '/Loader/Autoload.php');
15
+require_once(root.'/Loader/Autoload.php');
16 16
 
17 17
 // make fast-access alias \App::$Object
18 18
 // class_alias('Ffcms\Core\App', 'App');
Please login to merge, or discard this patch.
Extend/Core/Captcha/Gregwar.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -25,7 +25,7 @@
 block discarded – undo
25 25
      */
26 26
     public function get()
27 27
     {
28
-        return App::$Alias->scriptUrl . '/api/captcha/gregwar?time=' . microtime(true) . '&lang=' . App::$Request->getLanguage();
28
+        return App::$Alias->scriptUrl.'/api/captcha/gregwar?time='.microtime(true).'&lang='.App::$Request->getLanguage();
29 29
     }
30 30
 
31 31
     /**
Please login to merge, or discard this patch.
Apps/View/Front/default/widgets/contenttag/default.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,5 +5,5 @@
 block discarded – undo
5 5
 ?>
6 6
 
7 7
 <?php foreach ($records as $row) {
8
-    echo Url::link(['content/tag', $row['tag']], $row['tag'], ['class' => 'label label-default']) . ' ';
8
+    echo Url::link(['content/tag', $row['tag']], $row['tag'], ['class' => 'label label-default']).' ';
9 9
 }
10 10
\ No newline at end of file
Please login to merge, or discard this patch.
Apps/Model/Api/Comments/CommentPostAdd.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -57,7 +57,7 @@  discard block
 block discarded – undo
57 57
     public function check()
58 58
     {
59 59
         // check if user is auth'd or guest name is defined
60
-        if (!App::$User->isAuth() && ((int)$this->_configs['guestAdd'] !== 1 || Str::length($this->guestName) < 2)) {
60
+        if (!App::$User->isAuth() && ((int) $this->_configs['guestAdd'] !== 1 || Str::length($this->guestName) < 2)) {
61 61
             throw new JsonException(__('Guest name is not defined'));
62 62
         }
63 63
 
@@ -67,7 +67,7 @@  discard block
 block discarded – undo
67 67
         }
68 68
 
69 69
         // check if message length is correct
70
-        if (Str::length($this->message) < (int)$this->_configs['minLength'] || Str::length($this->message) > (int)$this->_configs['maxLength']) {
70
+        if (Str::length($this->message) < (int) $this->_configs['minLength'] || Str::length($this->message) > (int) $this->_configs['maxLength']) {
71 71
             throw new JsonException(__('Message length is incorrect. Current: %cur%, min - %min%, max - %max%', [
72 72
                 'cur' => Str::length($this->message),
73 73
                 'min' => $this->_configs['minLength'],
@@ -76,7 +76,7 @@  discard block
 block discarded – undo
76 76
         }
77 77
 
78 78
         // guest moderation
79
-        if (!App::$User->isAuth() && (bool)$this->_configs['guestModerate']) {
79
+        if (!App::$User->isAuth() && (bool) $this->_configs['guestModerate']) {
80 80
             $captcha = App::$Request->request->get('captcha');
81 81
             if (!App::$Captcha->validate($captcha)) {
82 82
                 throw new JsonException(__('Captcha is incorrect! Click on image to refresh and try again'));
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
         $record->message = $this->message;
115 115
         $record->lang = App::$Request->getLanguage();
116 116
         // check if premoderation is enabled and user is guest
117
-        if ((int)$this->_configs['guestModerate'] === 1 && $this->_userId < 1) {
117
+        if ((int) $this->_configs['guestModerate'] === 1 && $this->_userId < 1) {
118 118
             $record->moderate = 1;
119 119
         }
120 120
         $record->save();
Please login to merge, or discard this patch.
Apps/View/Admin/default/comments/index.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -26,7 +26,7 @@  discard block
 block discarded – undo
26 26
 
27 27
 <?php
28 28
 if ($records === null || $records->count() < 1) {
29
-    echo '<p class="alert alert-warning">' . __('Comments is not founded') . '</p>';
29
+    echo '<p class="alert alert-warning">'.__('Comments is not founded').'</p>';
30 30
     return;
31 31
 }
32 32
 $items = [];
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
 foreach ($records as $item) {
35 35
     $message = Text::cut(\App::$Security->strip_tags($item->message), 0, 75);
36 36
 
37
-    $moderate = (bool)$item->moderate;
37
+    $moderate = (bool) $item->moderate;
38 38
     // if even one moderate item is found - change global flag to true
39 39
     if ($moderate) {
40 40
         $moderateIsFound = true;
@@ -42,16 +42,16 @@  discard block
 block discarded – undo
42 42
 
43 43
     $items[] = [
44 44
         1 => ['text' => $item->id],
45
-        2 => ['text' => ($moderate ? '<i class="fa fa-exclamation text-warning"></i> ' : null) . Url::link(['comments/read', $item->id], $message), 'html' => true],
45
+        2 => ['text' => ($moderate ? '<i class="fa fa-exclamation text-warning"></i> ' : null).Url::link(['comments/read', $item->id], $message), 'html' => true],
46 46
         3 => ['text' => $item->getAnswerCount()],
47
-        4 => ['text' => Simplify::parseUserLink((int)$item->user_id, $item->guest_name, 'user/update'), 'html' => true],
48
-        5 => ['text' => '<a href="' . App::$Alias->scriptUrl . $item->pathway . '" target="_blank">' . Str::sub($item->pathway, 0, 20) . '...</a>', 'html' => true],
47
+        4 => ['text' => Simplify::parseUserLink((int) $item->user_id, $item->guest_name, 'user/update'), 'html' => true],
48
+        5 => ['text' => '<a href="'.App::$Alias->scriptUrl.$item->pathway.'" target="_blank">'.Str::sub($item->pathway, 0, 20).'...</a>', 'html' => true],
49 49
         6 => ['text' => Date::convertToDatetime($item->created_at, Date::FORMAT_TO_HOUR)],
50
-        7 => ['text' => Url::link(['comments/read', $item->id], '<i class="fa fa-list fa-lg"></i>') .
51
-            ' ' . Url::link(['comments/delete', 'comment', $item->id], '<i class="fa fa-trash-o fa-lg"></i>'),
50
+        7 => ['text' => Url::link(['comments/read', $item->id], '<i class="fa fa-list fa-lg"></i>').
51
+            ' '.Url::link(['comments/delete', 'comment', $item->id], '<i class="fa fa-trash-o fa-lg"></i>'),
52 52
             'html' => true, 'property' => ['class' => 'text-center']],
53 53
         'property' => [
54
-            'class' => 'checkbox-row' . ($moderate !== false ? ' alert-warning' : null)
54
+            'class' => 'checkbox-row'.($moderate !== false ? ' alert-warning' : null)
55 55
         ]
56 56
     ];
57 57
 }
Please login to merge, or discard this patch.
Apps/View/Admin/default/comments/comment_read.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -29,16 +29,16 @@  discard block
 block discarded – undo
29 29
             $author = Url::link(['user/update', $record->user_id], $author);
30 30
         }
31 31
         ?>
32
-        <?= $author . ', ' . Date::convertToDatetime($record->created_at, Date::FORMAT_TO_HOUR)  ?>
32
+        <?= $author.', '.Date::convertToDatetime($record->created_at, Date::FORMAT_TO_HOUR)  ?>
33 33
         <div class="pull-right">
34
-        	<?php if ((bool)$record->moderate):?>
34
+        	<?php if ((bool) $record->moderate):?>
35 35
         		<?= Url::link(['comments/publish', 'comment', $record->id], __('Publish'), ['class' => 'label label-warning']) ?>
36 36
         	<?php endif; ?>
37 37
             <?= Url::link(['comments/edit', 'comment', $record->id], __('Edit'), ['class' => 'label label-primary']) ?>
38 38
             <?= Url::link(['comments/delete', 'comment', $record->id], __('Delete'), ['class' => 'label label-danger']) ?>
39 39
         </div>
40 40
     </div>
41
-    <div class="panel-body<?= ((bool)$record->moderate ? ' text-warning' : null)?>">
41
+    <div class="panel-body<?= ((bool) $record->moderate ? ' text-warning' : null)?>">
42 42
         <?= $record->message ?>
43 43
     </div>
44 44
 </div>
@@ -59,16 +59,16 @@  discard block
 block discarded – undo
59 59
         <?php
60 60
         $answerAuthor = Simplify::parseUserLink($answer->user_id, $answer->guest_name, 'user/update');
61 61
         ?>
62
-        <?= $answerAuthor . ', ' . Date::convertToDatetime($answer->created_at, Date::FORMAT_TO_HOUR) ?>
62
+        <?= $answerAuthor.', '.Date::convertToDatetime($answer->created_at, Date::FORMAT_TO_HOUR) ?>
63 63
         <div class="pull-right">
64
-            <?php if ((bool)$answer->moderate):?>
64
+            <?php if ((bool) $answer->moderate):?>
65 65
         		<?= Url::link(['comments/publish', 'answer', $answer->id], __('Publish'), ['class' => 'label label-warning']) ?>
66 66
         	<?php endif; ?>
67 67
             <?= Url::link(['comments/edit', 'answer', $answer->id], __('Edit'), ['class' => 'label label-primary']) ?>
68 68
             <?= Url::link(['comments/delete', 'answer', $answer->id], __('Delete'), ['class' => 'label label-danger']) ?>
69 69
         </div>
70 70
     </div>
71
-    <div class="panel-body<?= ((bool)$answer->moderate ? ' text-warning' : null)?>">
71
+    <div class="panel-body<?= ((bool) $answer->moderate ? ' text-warning' : null)?>">
72 72
         <?= $answer->message ?>
73 73
     </div>
74 74
 </div>
Please login to merge, or discard this patch.
Apps/View/Front/default/content/update.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -32,10 +32,10 @@
 block discarded – undo
32 32
 foreach (\App::$Properties->get('languages') as $lang) {
33 33
     $items[] = [
34 34
         'type' => 'tab',
35
-        'text' => __('Lang') . ': ' . Str::upperCase($lang),
35
+        'text' => __('Lang').': '.Str::upperCase($lang),
36 36
         'content' =>
37
-            $form->field('title.' . $lang, 'text', ['class' => 'form-control'], __('Please, enter the title of your material for current language locale')) .
38
-            $form->field('text.' . $lang, 'textarea', ['class' => 'form-control wysiwyg', 'rows' => 7, 'html' => true]),
37
+            $form->field('title.'.$lang, 'text', ['class' => 'form-control'], __('Please, enter the title of your material for current language locale')).
38
+            $form->field('text.'.$lang, 'textarea', ['class' => 'form-control wysiwyg', 'rows' => 7, 'html' => true]),
39 39
         'html' => true,
40 40
         'active' => $lang === \App::$Request->getLanguage(),
41 41
         '!secure' => true
Please login to merge, or discard this patch.