Passed
Push — master ( 81f334...c86e8c )
by Mihail
03:35
created
Apps/Model/Admin/User/FormUserSettings.php 1 patch
Indentation   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -27,8 +27,8 @@
 block discarded – undo
27 27
     }
28 28
 
29 29
     /**
30
-    * Load configs from app data
31
-    */
30
+     * Load configs from app data
31
+     */
32 32
     public function before()
33 33
     {
34 34
         if ($this->_config === null) {
Please login to merge, or discard this patch.
Apps/Model/Admin/Content/FormContentClear.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
     {
44 44
         // remove gallery files if exists
45 45
         foreach ($this->_records->get() as $record) {
46
-            $galleryPath = '/upload/gallery/' . (int)$record->id;
46
+            $galleryPath = '/upload/gallery/'.(int) $record->id;
47 47
             if (Directory::exist($galleryPath)) {
48 48
                 Directory::remove($galleryPath);
49 49
             }
Please login to merge, or discard this patch.
Apps/Model/Front/User/FormLogin.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -70,7 +70,7 @@
 block discarded – undo
70 70
     {
71 71
         $password = App::$Security->password_hash($this->password);
72 72
 
73
-        $search = App::$User->where('password', '=', $password)->where(function ($query) {
73
+        $search = App::$User->where('password', '=', $password)->where(function($query) {
74 74
             $query->where('login', '=', $this->login)
75 75
                 ->orWhere('email', '=', $this->login);
76 76
         });
Please login to merge, or discard this patch.
Apps/Model/Front/Profile/FormSettings.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
 
72 72
         // labels for custom fields
73 73
         foreach (ProfileField::all() as $custom) {
74
-            $labels['custom_data.' . $custom->id] = $custom->getLocaled('name');
74
+            $labels['custom_data.'.$custom->id] = $custom->getLocaled('name');
75 75
         }
76 76
 
77 77
         return $labels;
@@ -97,12 +97,12 @@  discard block
 block discarded – undo
97 97
         // custom profile fields
98 98
         foreach (ProfileField::all() as $custom) {
99 99
             $rules[] = [
100
-                'custom_data.' . $custom->id,
100
+                'custom_data.'.$custom->id,
101 101
                 'used'
102 102
             ];
103 103
             $rules[] = [
104
-                'custom_data.' . $custom->id,
105
-                (int)$custom->reg_cond === 1 ? 'direct_match' : 'reverse_match',
104
+                'custom_data.'.$custom->id,
105
+                (int) $custom->reg_cond === 1 ? 'direct_match' : 'reverse_match',
106 106
                 $custom->reg_exp
107 107
             ];
108 108
         }
Please login to merge, or discard this patch.
Apps/ActiveRecord/ContentCategory.php 1 patch
Spacing   +9 added lines, -9 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
      */
35 35
     public static function all($columns = ['*'])
36 36
     {
37
-        $cacheName = 'activerecord.contentcategory.all.' . implode('.', $columns);
37
+        $cacheName = 'activerecord.contentcategory.all.'.implode('.', $columns);
38 38
         $records = MemoryObject::instance()->get($cacheName);
39 39
         if ($records === null) {
40 40
             $records = parent::all($columns);
@@ -50,12 +50,12 @@  discard block
 block discarded – undo
50 50
      */
51 51
     public static function getByPath($path = '')
52 52
     {
53
-        if (MainApp::$Memory->get('cache.content.category.path.' . $path) !== null) {
54
-            return MainApp::$Memory->get('cache.content.category.path.' . $path);
53
+        if (MainApp::$Memory->get('cache.content.category.path.'.$path) !== null) {
54
+            return MainApp::$Memory->get('cache.content.category.path.'.$path);
55 55
         }
56 56
 
57 57
         $record = self::where('path', '=', $path)->first();
58
-        MainApp::$Memory->set('cache.content.category.path.' . $path, $record);
58
+        MainApp::$Memory->set('cache.content.category.path.'.$path, $record);
59 59
         return $record;
60 60
     }
61 61
 
@@ -66,12 +66,12 @@  discard block
 block discarded – undo
66 66
      */
67 67
     public static function getById($id)
68 68
     {
69
-        if (MainApp::$Memory->get('cache.content.category.id.' . $id) !== null) {
70
-            return MainApp::$Memory->get('cache.content.category.id.' . $id);
69
+        if (MainApp::$Memory->get('cache.content.category.id.'.$id) !== null) {
70
+            return MainApp::$Memory->get('cache.content.category.id.'.$id);
71 71
         }
72 72
 
73 73
         $record = self::find($id);
74
-        MainApp::$Memory->set('cache.content.category.id.' . $id, $record);
74
+        MainApp::$Memory->set('cache.content.category.id.'.$id, $record);
75 75
         return $record;
76 76
     }
77 77
 
@@ -99,12 +99,12 @@  discard block
 block discarded – undo
99 99
             } else {
100 100
                 // set level marker based on slashes count in pathway
101 101
                 $slashCount = Str::entryCount($path, '/');
102
-                for ($i=-1; $i <= $slashCount; $i++) {
102
+                for ($i = -1; $i <= $slashCount; $i++) {
103 103
                     $title .= '--';
104 104
                 }
105 105
             }
106 106
             // add canonical title from db
107
-            $title .= ' ' . $data->getLocaled('title');
107
+            $title .= ' '.$data->getLocaled('title');
108 108
             // set response as array [id => title, ... ]
109 109
             $response[$data->id] = $title;
110 110
         }
Please login to merge, or discard this patch.
Apps/View/Front/default/widgets/newcontent/default.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -12,15 +12,15 @@
 block discarded – undo
12 12
     }
13 13
     $title = Text::snippet($title, 50);
14 14
     $date = Date::humanize($record->created_at);
15
-    $categoryUrl = \App::$Alias->baseUrl . '/content/list/' . $record->cpath;
16
-    $categoryLink = '<a href="' . $categoryUrl . '">' . \App::$Translate->getLocaleText($record->ctitle) . '</a>';
17
-    $newsLink = \App::$Alias->baseUrl . '/content/read/' . $record->cpath;
18
-    $newsLink = rtrim($newsLink, '/') . '/' . $record->path;
15
+    $categoryUrl = \App::$Alias->baseUrl.'/content/list/'.$record->cpath;
16
+    $categoryLink = '<a href="'.$categoryUrl.'">'.\App::$Translate->getLocaleText($record->ctitle).'</a>';
17
+    $newsLink = \App::$Alias->baseUrl.'/content/read/'.$record->cpath;
18
+    $newsLink = rtrim($newsLink, '/').'/'.$record->path;
19 19
     
20 20
     echo '<div class="row"><div class="col-md-12">';
21
-    echo '<a href="' . $newsLink . '">&rarr; ' . $title . '</a><br />';
22
-    echo '<small class="pull-left">' . $categoryLink . '</small>';
23
-    echo '<small class="pull-right">' . $date . '</small>';
21
+    echo '<a href="'.$newsLink.'">&rarr; '.$title.'</a><br />';
22
+    echo '<small class="pull-left">'.$categoryLink.'</small>';
23
+    echo '<small class="pull-right">'.$date.'</small>';
24 24
     echo '</div></div>';
25 25
     echo '<hr class="pretty" />';
26 26
 }
Please login to merge, or discard this patch.
Apps/Model/Admin/Application/FormInstall.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
     public function before()
44 44
     {
45 45
         foreach ($this->_apps as $app) {
46
-            $this->_definedControllers[] = (string)$app->sys_name;
46
+            $this->_definedControllers[] = (string) $app->sys_name;
47 47
         }
48 48
 
49 49
         parent::before();
@@ -79,14 +79,14 @@  discard block
 block discarded – undo
79 79
     public function make()
80 80
     {
81 81
         $cName = ucfirst(Str::lowerCase($this->sysname));
82
-        $cPath = 'Apps\Controller\Admin\\' . $cName;
82
+        $cPath = 'Apps\Controller\Admin\\'.$cName;
83 83
         // if object class is not loaded - prevent install
84
-        if (!class_exists($cPath) || !defined($cPath . '::VERSION')) {
84
+        if (!class_exists($cPath) || !defined($cPath.'::VERSION')) {
85 85
             return false;
86 86
         }
87 87
 
88 88
         // get ext version
89
-        $cVersion = constant($cPath . '::VERSION');
89
+        $cVersion = constant($cPath.'::VERSION');
90 90
         if ($cVersion === null || Str::likeEmpty($cVersion)) {
91 91
             $cVersion = '1.0.0';
92 92
         }
@@ -102,7 +102,7 @@  discard block
 block discarded – undo
102 102
 
103 103
         // callback to install method in extension
104 104
         if (method_exists($cPath, 'install')) {
105
-            call_user_func($cPath . '::install');
105
+            call_user_func($cPath.'::install');
106 106
         }
107 107
 
108 108
         return true;
Please login to merge, or discard this patch.
Apps/Model/Admin/Content/FormContentPublish.php 1 patch
Doc Comments   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -17,7 +17,7 @@
 block discarded – undo
17 17
 
18 18
     /**
19 19
      * FormContentPublish constructor. Pass records inside
20
-     * @param Content[]|Collection $records
20
+     * @param \Ffcms\Core\Arch\ActiveModel $records
21 21
      */
22 22
     public function __construct($records)
23 23
     {
Please login to merge, or discard this patch.
Apps/Model/Admin/Main/FormUpdateDownload.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -34,12 +34,12 @@
 block discarded – undo
34 34
      */
35 35
     public function make()
36 36
     {
37
-        $archive = $this->name . '.zip';
37
+        $archive = $this->name.'.zip';
38 38
         // download archive
39
-        File::saveFromUrl($this->url, '/' . $archive);
39
+        File::saveFromUrl($this->url, '/'.$archive);
40 40
         // extract archive
41 41
         $zip = new \ZipArchive();
42
-        if ($zip->open(root . '/' . $archive) === true) {
42
+        if ($zip->open(root.'/'.$archive) === true) {
43 43
             $zip->extractTo(root);
44 44
             $zip->close();
45 45
             // cleanup cache
Please login to merge, or discard this patch.