Completed
Pull Request — master (#2002)
by
unknown
02:41
created
core/theme/ThemeManager.php 1 patch
Spacing   +7 added lines, -7 removed lines patch added patch discarded remove patch
@@ -55,7 +55,7 @@  discard block
 block discarded – undo
55 55
             $dir = $basePath;
56 56
         } else {
57 57
             // relative path
58
-            throw new InvalidConfigException('Theme base path have to be absolute or alias: ' . $basePath);
58
+            throw new InvalidConfigException('Theme base path have to be absolute or alias: '.$basePath);
59 59
         }
60 60
 
61 61
         // $basePath is an absolute path = /VENDOR/NAME/theme.json
@@ -65,12 +65,12 @@  discard block
 block discarded – undo
65 65
             $basePath = pathinfo($basePath, PATHINFO_DIRNAME);
66 66
         } else {
67 67
             if (!is_dir($dir) || !is_readable($dir)) {
68
-                throw new Exception('Theme directory not exists or readable: ' . $dir);
68
+                throw new Exception('Theme directory not exists or readable: '.$dir);
69 69
             }
70 70
 
71
-            $themeFile = $dir . DIRECTORY_SEPARATOR . 'theme.json';
71
+            $themeFile = $dir.DIRECTORY_SEPARATOR.'theme.json';
72 72
             if (!file_exists($themeFile)) {
73
-                throw new InvalidConfigException('Theme config file missing at: ' . $themeFile);
73
+                throw new InvalidConfigException('Theme config file missing at: '.$themeFile);
74 74
             }
75 75
         }
76 76
         
@@ -172,7 +172,7 @@  discard block
 block discarded – undo
172 172
         
173 173
         if (file_exists(Yii::getAlias('@app/themes'))) {
174 174
             foreach (glob(Yii::getAlias('@app/themes/*')) as $dirPath) {
175
-                $themeDefinitions[] = "@app/themes/" . basename($dirPath);
175
+                $themeDefinitions[] = "@app/themes/".basename($dirPath);
176 176
             }
177 177
         }
178 178
         
@@ -182,7 +182,7 @@  discard block
 block discarded – undo
182 182
                 if (strpos($theme, '@') === 0 || strpos($theme, '/') === 0) {
183 183
                     $themeDefinitions[] = $theme;
184 184
                 } else {
185
-                    $themeDefinitions[] = '@vendor' . DIRECTORY_SEPARATOR . $config->package['packageFolder'] . DIRECTORY_SEPARATOR . $theme;
185
+                    $themeDefinitions[] = '@vendor'.DIRECTORY_SEPARATOR.$config->package['packageFolder'].DIRECTORY_SEPARATOR.$theme;
186 186
                 }
187 187
             }
188 188
         }
@@ -225,7 +225,7 @@  discard block
 block discarded – undo
225 225
         
226 226
         $this->_themes[$basePath] = $themeConfig;
227 227
         
228
-        Yii::setAlias('@' . basename($basePath) . 'Theme', $basePath);
228
+        Yii::setAlias('@'.basename($basePath).'Theme', $basePath);
229 229
     }
230 230
     
231 231
     /**
Please login to merge, or discard this patch.