Passed
Push — master ( a806b2...aff34e )
by Mihail
04:14
created
Apps/Model/Admin/Content/FormCategoryUpdate.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
         ];
113 113
 
114 114
         // general category
115
-        if ($this->_new === false && (int)$this->_record->id === 1) {
115
+        if ($this->_new === false && (int) $this->_record->id === 1) {
116 116
             $rules[] = ['path', 'used'];
117 117
         } else {
118 118
             $rules[] = ['path', 'required'];
@@ -121,7 +121,7 @@  discard block
 block discarded – undo
121 121
             $rules[] = ['path', 'reverse_match', '/[\/\'~`\!@#\$%\^&\*\(\)+=\{\}\[\]\|;:"\<\>,\?\\\]/'];
122 122
         }
123 123
 
124
-        $rules[] = ['title.' . App::$Request->getLanguage(), 'required'];
124
+        $rules[] = ['title.'.App::$Request->getLanguage(), 'required'];
125 125
 
126 126
 
127 127
         return $rules;
@@ -134,7 +134,7 @@  discard block
 block discarded – undo
134 134
     {
135 135
         $this->_record->title = $this->title;
136 136
         $this->_record->description = $this->description;
137
-        $savePath = trim($this->_pathNested . '/' . $this->path, '/');
137
+        $savePath = trim($this->_pathNested.'/'.$this->path, '/');
138 138
         $this->_record->path = $savePath;
139 139
         $this->_record->configs = $this->configs;
140 140
         $this->_record->save();
@@ -169,7 +169,7 @@  discard block
 block discarded – undo
169 169
         // build path with owner category
170 170
         $this->_pathNested = $owner->path;
171 171
         if (Str::length($this->_pathNested) > 0) {
172
-            $path = $this->_pathNested . '/' . $path;
172
+            $path = $this->_pathNested.'/'.$path;
173 173
         }
174 174
 
175 175
         // make select for check
Please login to merge, or discard this patch.
Apps/Model/Admin/Content/FormCategoryDelete.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -80,7 +80,7 @@
 block discarded – undo
80 80
         }
81 81
 
82 82
         // get all depended category ids
83
-        $cats = ContentCategory::where('path', 'like', $this->_record->path . '%')->get(['id'])->toArray();
83
+        $cats = ContentCategory::where('path', 'like', $this->_record->path.'%')->get(['id'])->toArray();
84 84
         $allCategoryIds = Arr::pluck('id', $cats);
85 85
 
86 86
         // update category_id in content
Please login to merge, or discard this patch.
Apps/Model/Admin/Contenttag/FormSettings.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -30,8 +30,8 @@
 block discarded – undo
30 30
      */
31 31
     public function before()
32 32
     {
33
-        $this->count = (int)$this->_configs['count'];
34
-        $this->cache = (int)$this->_configs['cache'];
33
+        $this->count = (int) $this->_configs['count'];
34
+        $this->cache = (int) $this->_configs['cache'];
35 35
     }
36 36
 
37 37
     /**
Please login to merge, or discard this patch.
Apps/Model/Admin/Application/FormTurn.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -30,7 +30,7 @@
 block discarded – undo
30 30
     {
31 31
         $status = $this->_record->disabled;
32 32
 
33
-        $this->_record->disabled = (int)!$status; // magic inside: bool to int and reverse - 0 => 1, 1 => 0
33
+        $this->_record->disabled = (int) !$status; // magic inside: bool to int and reverse - 0 => 1, 1 => 0
34 34
         $this->_record->save();
35 35
     }
36 36
 }
Please login to merge, or discard this patch.
Apps/Model/Admin/Newcomment/FormSettings.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -31,9 +31,9 @@
 block discarded – undo
31 31
      */
32 32
     public function before()
33 33
     {
34
-        $this->snippet = (int)$this->_configs['snippet'];
35
-        $this->count = (int)$this->_configs['count'];
36
-        $this->cache = (int)$this->_configs['cache'];
34
+        $this->snippet = (int) $this->_configs['snippet'];
35
+        $this->count = (int) $this->_configs['count'];
36
+        $this->cache = (int) $this->_configs['cache'];
37 37
     }
38 38
 
39 39
     /**
Please login to merge, or discard this patch.
Apps/Model/Admin/User/FormUserDelete.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -69,10 +69,10 @@
 block discarded – undo
69 69
                 ->orWhere('sender_id', '=', $uid)
70 70
                 ->delete();
71 71
             // delete avatars
72
-            File::remove('/upload/user/avatar/big/' . $uid . '.jpg');
73
-            File::remove('/upload/user/avatar/medium/' . $uid . '.jpg');
74
-            File::remove('/upload/user/avatar/small/' . $uid . '.jpg');
75
-            File::remove('/upload/user/avatar/original/' . $uid . '.jpg');
72
+            File::remove('/upload/user/avatar/big/'.$uid.'.jpg');
73
+            File::remove('/upload/user/avatar/medium/'.$uid.'.jpg');
74
+            File::remove('/upload/user/avatar/small/'.$uid.'.jpg');
75
+            File::remove('/upload/user/avatar/original/'.$uid.'.jpg');
76 76
             // delete user profile and auth data
77 77
             $user->profile()->delete();
78 78
             // delete user provider data
Please login to merge, or discard this patch.
Apps/Model/Admin/Newcontent/FormSettings.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -36,8 +36,8 @@
 block discarded – undo
36 36
             return;
37 37
         }
38 38
         $this->categories = $this->_configs['categories'];
39
-        $this->count = (int)$this->_configs['count'];
40
-        $this->cache = (int)$this->_configs['cache'];
39
+        $this->count = (int) $this->_configs['count'];
40
+        $this->cache = (int) $this->_configs['cache'];
41 41
     }
42 42
 
43 43
     /**
Please login to merge, or discard this patch.
Apps/Model/Admin/Main/FormUpdateDatabase.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -43,7 +43,7 @@
 block discarded – undo
43 43
             $name = Str::firstIn($fullName, '-');
44 44
             // get update version number from migration name
45 45
             list($type, $obj, $version) = explode('_', $name);
46
-            $intVersion = (int)Str::replace('.', '', $this->dbVersion);
46
+            $intVersion = (int) Str::replace('.', '', $this->dbVersion);
47 47
             // if migration version > db version - implement it
48 48
             if ($version > $intVersion) {
49 49
                 $this->updateQueries[] = $file;
Please login to merge, or discard this patch.
Apps/Model/Install/Main/FormInstall.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -105,14 +105,14 @@
 block discarded – undo
105 105
         $cfg['baseDomain'] = $this->baseDomain;
106 106
         $cfg['database'] = $this->db;
107 107
         $cfg['singleLanguage'] = $this->singleLanguage;
108
-        $cfg['multiLanguage'] = (bool)$this->multiLanguage;
109
-        $cfg['passwordSalt'] = '$2a$07$' . Str::randomLatinNumeric(mt_rand(21, 30)) . '$';
110
-        $cfg['debug']['cookie']['key'] = 'fdebug_' . Str::randomLatinNumeric(mt_rand(4, 16));
108
+        $cfg['multiLanguage'] = (bool) $this->multiLanguage;
109
+        $cfg['passwordSalt'] = '$2a$07$'.Str::randomLatinNumeric(mt_rand(21, 30)).'$';
110
+        $cfg['debug']['cookie']['key'] = 'fdebug_'.Str::randomLatinNumeric(mt_rand(4, 16));
111 111
         $cfg['debug']['cookie']['value'] = Str::randomLatinNumeric(mt_rand(32, 128));
112 112
         $cfg['mail'] = $this->mail;
113 113
 
114 114
         // initialize migrations table
115
-        App::$Database->getConnection('install')->getSchemaBuilder()->create('migrations', function ($table) {
115
+        App::$Database->getConnection('install')->getSchemaBuilder()->create('migrations', function($table) {
116 116
             $table->increments('id');
117 117
             $table->string('migration', 128)->unique();
118 118
             $table->timestamps();
Please login to merge, or discard this patch.