Passed
Pull Request — master (#84)
by
unknown
04:59
created
modules/admin/views/monitoring/tags.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -45,7 +45,7 @@
 block discarded – undo
45 45
 
46 46
                     [
47 47
                         'attribute' => 'name',
48
-                        'content' => function (\app\models\Tag $model) {
48
+                        'content' => function(\app\models\Tag $model) {
49 49
                             $html = [];
50 50
                             $html[] = Html::a($model->namePrefixed, ['tag/stats', 'id' => $model->id]);
51 51
                             $html[] = Html::a('<span class="fa fa-external-link text-sm"></span>', Url::tag($model->name), ['target' => '_blank']);
Please login to merge, or discard this patch.
components/TagManager.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@  discard block
 block discarded – undo
43 43
      */
44 44
     public function updateInvalidation(Tag $tag, ?int $invalidationType)
45 45
     {
46
-        $tag->invalidation_count = (int)$tag->invalidation_count + 1;
46
+        $tag->invalidation_count = (int) $tag->invalidation_count + 1;
47 47
         $tag->is_valid = 0;
48 48
         $tag->invalidation_type_id = $invalidationType;
49 49
         $interval = 1;
@@ -84,7 +84,7 @@  discard block
 block discarded – undo
84 84
     {
85 85
         $this->saveTags($tags);
86 86
 
87
-        $rows = array_map(function ($id) use ($media) {
87
+        $rows = array_map(function($id) use ($media) {
88 88
             return [
89 89
                 $media->id,
90 90
                 $id,
@@ -132,7 +132,7 @@  discard block
 block discarded – undo
132 132
         $userIds = $this->getUserIds($userId);
133 133
         $tagIds = $this->getTagIds($tags);
134 134
         foreach ($userIds as $userId) {
135
-            $tmp = array_map(function ($tagId) use ($account, $userId, $createdAt) {
135
+            $tmp = array_map(function($tagId) use ($account, $userId, $createdAt) {
136 136
                 return [
137 137
                     $account->id,
138 138
                     $tagId,
@@ -157,7 +157,7 @@  discard block
 block discarded – undo
157 157
     public function saveTags(array $tags)
158 158
     {
159 159
         $createdAt = (new \DateTime())->format('Y-m-d H:i:s');
160
-        $rows = array_map(function ($tag) use ($createdAt) {
160
+        $rows = array_map(function($tag) use ($createdAt) {
161 161
             return [
162 162
                 $tag,
163 163
                 Inflector::slug($tag),
@@ -202,7 +202,7 @@  discard block
 block discarded – undo
202 202
                 ->andWhere(['active' => 1])
203 203
                 ->column();
204 204
         } else {
205
-            $userIds = (array)$userId;
205
+            $userIds = (array) $userId;
206 206
         }
207 207
 
208 208
         return $userIds;
Please login to merge, or discard this patch.
components/AccountManager.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
 
37 37
     public function updateInvalidation(Account $account, ?int $invalidationType)
38 38
     {
39
-        $account->invalidation_count = (int)$account->invalidation_count + 1;
39
+        $account->invalidation_count = (int) $account->invalidation_count + 1;
40 40
         $account->is_valid = 0;
41 41
         $account->invalidation_type_id = $invalidationType;
42 42
         $interval = 1;
@@ -104,7 +104,7 @@  discard block
 block discarded – undo
104 104
     {
105 105
         $this->saveUsernames($usernames);
106 106
 
107
-        $rows = array_map(function ($id) use ($media) {
107
+        $rows = array_map(function($id) use ($media) {
108 108
             return [
109 109
                 $media->id,
110 110
                 $id,
@@ -128,7 +128,7 @@  discard block
 block discarded – undo
128 128
     public function saveUsernames(array $usernames)
129 129
     {
130 130
         $createdAt = (new \DateTime())->format('Y-m-d H:i:s');
131
-        $rows = array_map(function ($username) use ($createdAt) {
131
+        $rows = array_map(function($username) use ($createdAt) {
132 132
             return [
133 133
                 $username,
134 134
                 $createdAt,
Please login to merge, or discard this patch.
modules/admin/views/account/media-accounts.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -36,7 +36,7 @@  discard block
 block discarded – undo
36 36
                                 [
37 37
                                     'attribute' => 'username',
38 38
                                     'format' => 'raw',
39
-                                    'value' => function (Account $model, $key, $index, $column) {
39
+                                    'value' => function(Account $model, $key, $index, $column) {
40 40
                                         if ($model->monitoring) {
41 41
                                             $value = Html::a($model->usernamePrefixed, ['account/dashboard', 'id' => $model->id]);
42 42
                                         } else {
@@ -49,7 +49,7 @@  discard block
 block discarded – undo
49 49
                                 [
50 50
                                     'attribute' => 'er',
51 51
                                     'format' => 'raw',
52
-                                    'value' => function (Account $model) use ($formatter) {
52
+                                    'value' => function(Account $model) use ($formatter) {
53 53
                                         if ($model->er) {
54 54
                                             return sprintf('<span data-toggle="tooltip" data-placement="top" title="updated at: %s">%s</span>',
55 55
                                                 $formatter->asDate($model->stats_updated_at),
@@ -63,7 +63,7 @@  discard block
 block discarded – undo
63 63
                                 'occurs',
64 64
                                 [
65 65
                                     'format' => 'raw',
66
-                                    'value' => function (Account $account) use ($model) {
66
+                                    'value' => function(Account $account) use ($model) {
67 67
                                         return OnOffMonitoringButton::widget([
68 68
                                             'model' => $account,
69 69
                                             'form' => new MonitoringForm([
Please login to merge, or discard this patch.
modules/admin/views/auth/login.php 2 patches
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -19,9 +19,9 @@
 block discarded – undo
19 19
 <?php foreach ($authAuthChoice->getClients() as $client): ?>
20 20
     <div class="form-group text-center">
21 21
         <?php if ($client->getId() == 'google'): ?>
22
-            <?= Html::a(Html::img('/img/btn_google_signin.png'), ['/admin/auth/auth', 'authclient' => $client->getName(),]) ?>
22
+            <?= Html::a(Html::img('/img/btn_google_signin.png'), ['/admin/auth/auth', 'authclient' => $client->getName(), ]) ?>
23 23
         <?php else: ?>
24
-            <?= Html::a("<span class='fa fa-$client->name'></span> Sign in with " . $client->getTitle(), ['/admin/auth/auth', 'authclient' => $client->getName(),], ['class' => "btn btn-block btn-social btn-$client->name "]) ?>
24
+            <?= Html::a("<span class='fa fa-$client->name'></span> Sign in with " . $client->getTitle(), ['/admin/auth/auth', 'authclient' => $client->getName(), ], ['class' => "btn btn-block btn-social btn-$client->name "]) ?>
25 25
         <?php endif; ?>
26 26
     </div>
27 27
 <?php endforeach; ?>
Please login to merge, or discard this patch.
Braces   +5 added lines, -2 removed lines patch added patch discarded remove patch
@@ -20,9 +20,12 @@
 block discarded – undo
20 20
     <div class="form-group text-center">
21 21
         <?php if ($client->getId() == 'google'): ?>
22 22
             <?= Html::a(Html::img('/img/btn_google_signin.png'), ['/admin/auth/auth', 'authclient' => $client->getName(),]) ?>
23
-        <?php else: ?>
23
+        <?php else {
24
+    : ?>
24 25
             <?= Html::a("<span class='fa fa-$client->name'></span> Sign in with " . $client->getTitle(), ['/admin/auth/auth', 'authclient' => $client->getName(),], ['class' => "btn btn-block btn-social btn-$client->name "]) ?>
25
-        <?php endif; ?>
26
+        <?php endif;
27
+}
28
+?>
26 29
     </div>
27 30
 <?php endforeach; ?>
28 31
 <?php AuthChoice::end() ?>
29 32
\ No newline at end of file
Please login to merge, or discard this patch.