@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | |
47 | 47 | $this->scanFiles = json_decode(File::read('/Private/Antivirus/ScanFiles.json')); |
48 | 48 | if (File::exist('/Private/Antivirus/Infected.json')) { |
49 | - $this->infected = (array)json_decode(File::read('/Private/Antivirus/Infected.json')); |
|
49 | + $this->infected = (array) json_decode(File::read('/Private/Antivirus/Infected.json')); |
|
50 | 50 | } |
51 | 51 | } |
52 | 52 | |
@@ -114,7 +114,7 @@ discard block |
||
114 | 114 | $detected = true; |
115 | 115 | $pos = $found[0][1]; |
116 | 116 | $this->infected[$path][] = [ |
117 | - 'pos' => (int)$pos, |
|
117 | + 'pos' => (int) $pos, |
|
118 | 118 | 'sigId' => $attrId, |
119 | 119 | 'sigRule' => $sigContent, |
120 | 120 | 'sever' => $attrSever, |
@@ -128,7 +128,7 @@ discard block |
||
128 | 128 | (($pos = strpos($normalized, $sigContent)) !== false) |
129 | 129 | ) { |
130 | 130 | $this->infected[$path][] = [ |
131 | - 'pos' => (int)$pos, |
|
131 | + 'pos' => (int) $pos, |
|
132 | 132 | 'sigId' => $attrId, |
133 | 133 | 'sigRule' => $sigContent, |
134 | 134 | 'sever' => $attrSever, |
@@ -148,7 +148,7 @@ discard block |
||
148 | 148 | */ |
149 | 149 | private function prepareScanlist() |
150 | 150 | { |
151 | - $files = (object)File::listFiles(root, $this->affectedExt); |
|
151 | + $files = (object) File::listFiles(root, $this->affectedExt); |
|
152 | 152 | File::write('/Private/Antivirus/ScanFiles.json', json_encode($files)); |
153 | 153 | } |
154 | 154 |
@@ -86,7 +86,7 @@ |
||
86 | 86 | $this->authorName = Str::likeEmpty($profile->nick) ? __('No name') : $profile->nick; |
87 | 87 | } |
88 | 88 | $this->source = $this->_content->source; |
89 | - $this->views = $this->_content->views+1; |
|
89 | + $this->views = $this->_content->views + 1; |
|
90 | 90 | // check for dependence, add '' for general cat, ex: general/depend1/depend2/.../depend-n |
91 | 91 | $catNestingArray = Arr::merge([0 => ''], explode('/', $this->catPath)); |
92 | 92 | if ($catNestingArray > 1) { |
@@ -52,7 +52,7 @@ |
||
52 | 52 | public function save() |
53 | 53 | { |
54 | 54 | // check if target is myself or always exist in block list |
55 | - if ($this->_user->getId() === (int)$this->id || Blacklist::have($this->_user->getId(), $this->id)) { |
|
55 | + if ($this->_user->getId() === (int) $this->id || Blacklist::have($this->_user->getId(), $this->id)) { |
|
56 | 56 | return false; |
57 | 57 | } |
58 | 58 |
@@ -56,7 +56,7 @@ discard block |
||
56 | 56 | */ |
57 | 57 | public function labels() |
58 | 58 | { |
59 | - $labels = [ |
|
59 | + $labels = [ |
|
60 | 60 | 'nick' => __('Nickname'), |
61 | 61 | 'sex' => __('Sex'), |
62 | 62 | 'birthday' => __('Birthday'), |
@@ -98,7 +98,7 @@ discard block |
||
98 | 98 | ]; |
99 | 99 | $rules[] = [ |
100 | 100 | 'custom_data.' . $custom->id, |
101 | - (int)$custom->reg_cond === 1 ? 'direct_match' : 'reverse_match', |
|
101 | + (int) $custom->reg_cond === 1 ? 'direct_match' : 'reverse_match', |
|
102 | 102 | $custom->reg_exp |
103 | 103 | ]; |
104 | 104 | } |
@@ -31,7 +31,7 @@ |
||
31 | 31 | [['text' => __('Name')], ['text' => $app->getLocaleName()]], |
32 | 32 | [['text' => __('System name')], ['text' => $app->sys_name]], |
33 | 33 | [['text' => __('Last update')], ['text' => Date::convertToDatetime($app->updated_at, DATE::FORMAT_TO_SECONDS)]], |
34 | - [['text' => __('Status')], ['text' => ((int)$app->disabled === 0) ? 'On' : 'Off'], 'property' => ['class' => ((int)$app->disabled === 0) ? 'alert-success' : 'alert-danger']] |
|
34 | + [['text' => __('Status')], ['text' => ((int) $app->disabled === 0) ? 'On' : 'Off'], 'property' => ['class' => ((int) $app->disabled === 0) ? 'alert-success' : 'alert-danger']] |
|
35 | 35 | ] |
36 | 36 | ] |
37 | 37 | ]); ?> |
@@ -55,8 +55,8 @@ |
||
55 | 55 | <tr> |
56 | 56 | <td> |
57 | 57 | <div class="row"> |
58 | - <div class="col-md-<?= $offset ?> col-xs-<?= $offset+2 ?>" style="padding-top: 8px;border-bottom: 2px solid #8a8a8a"></div> |
|
59 | - <div class="col-md-<?= $set ?> col-xs-<?= $set-2 ?>"> |
|
58 | + <div class="col-md-<?= $offset ?> col-xs-<?= $offset + 2 ?>" style="padding-top: 8px;border-bottom: 2px solid #8a8a8a"></div> |
|
59 | + <div class="col-md-<?= $set ?> col-xs-<?= $set - 2 ?>"> |
|
60 | 60 | <?= Serialize::getDecodeLocale($row->title) ?> |
61 | 61 | <span class="label label-info">/<?= $row->path ?></span> |
62 | 62 | </div> |
@@ -51,7 +51,7 @@ |
||
51 | 51 | $pathProperty = [ |
52 | 52 | 'class' => 'form-control' |
53 | 53 | ]; |
54 | -if ((int)$model->id == '1') { |
|
54 | +if ((int) $model->id == '1') { |
|
55 | 55 | $pathProperty['disabled'] = ''; |
56 | 56 | } else { |
57 | 57 | echo $form->field('dependId', 'select', ['class' => 'form-control', 'options' => $model->categoryList(), 'optionsKey' => true], __('Select owner category for this category')); |
@@ -110,7 +110,7 @@ |
||
110 | 110 | ['type' => 'tab', 'text' => __('Gallery'), 'content' => $galleryTab, 'html' => true, '!secure' => true], |
111 | 111 | ['type' => 'tab', 'text' => __('Other'), 'content' => $otherTab, 'html' => true, '!secure' => true] |
112 | 112 | ] |
113 | -]);?> |
|
113 | +]); ?> |
|
114 | 114 | |
115 | 115 | <?= $form->field('galleryFreeId', 'hidden') ?> |
116 | 116 | <?= $form->submitButton(__('Save'), ['class' => 'btn btn-primary']) ?> |
@@ -35,7 +35,7 @@ |
||
35 | 35 | 'items' => [ |
36 | 36 | [['text' => $model->getLabel('name')], ['text' => $model->name[\App::$Request->getLanguage()]]], |
37 | 37 | [['text' => $model->getLabel('type')], ['text' => $model->type]], |
38 | - [['text' => $model->getLabel('reg_exp')], ['text' => ($model->reg_cond == 0 ? '!' : null) . 'preg_match("'.$model->reg_exp.'", $input)']], |
|
38 | + [['text' => $model->getLabel('reg_exp')], ['text' => ($model->reg_cond == 0 ? '!' : null) . 'preg_match("' . $model->reg_exp . '", $input)']], |
|
39 | 39 | ] |
40 | 40 | ] |
41 | 41 | ]); |