@@ -266,7 +266,7 @@ discard block |
||
| 266 | 266 | } |
| 267 | 267 | } catch (InvalidParamException $e) { |
| 268 | 268 | try { |
| 269 | - $staticPath = static::staticBasePath() . DIRECTORY_SEPARATOR . 'controllers'; |
|
| 269 | + $staticPath = static::staticBasePath().DIRECTORY_SEPARATOR.'controllers'; |
|
| 270 | 270 | foreach (FileHelper::findFiles($staticPath) as $file) { |
| 271 | 271 | $files[$this->fileToName($staticPath, $file)] = $file; |
| 272 | 272 | } |
@@ -294,7 +294,7 @@ discard block |
||
| 294 | 294 | */ |
| 295 | 295 | public function getControllerPath() |
| 296 | 296 | { |
| 297 | - return Yii::getAlias('@' . str_replace('\\', '/', $this->controllerNamespace), false); |
|
| 297 | + return Yii::getAlias('@'.str_replace('\\', '/', $this->controllerNamespace), false); |
|
| 298 | 298 | } |
| 299 | 299 | |
| 300 | 300 | // STATIC METHODS |
@@ -332,7 +332,7 @@ discard block |
||
| 332 | 332 | */ |
| 333 | 333 | public static function registerTranslation($prefix, $basePath, array $fileMap) |
| 334 | 334 | { |
| 335 | - if(!isset(Yii::$app->i18n->translations[$prefix])){ |
|
| 335 | + if (!isset(Yii::$app->i18n->translations[$prefix])) { |
|
| 336 | 336 | Yii::$app->i18n->translations[$prefix] = [ |
| 337 | 337 | 'class' => 'yii\i18n\PhpMessageSource', |
| 338 | 338 | 'basePath' => $basePath, |
@@ -127,7 +127,7 @@ discard block |
||
| 127 | 127 | case 'cn': |
| 128 | 128 | return 'cn_CN'; |
| 129 | 129 | default: |
| 130 | - return strtolower($lang) . '_' . strtoupper($lang); |
|
| 130 | + return strtolower($lang).'_'.strtoupper($lang); |
|
| 131 | 131 | } |
| 132 | 132 | } |
| 133 | 133 | |
@@ -182,7 +182,7 @@ discard block |
||
| 182 | 182 | public function getWebroot() |
| 183 | 183 | { |
| 184 | 184 | if ($this->_webroot === null) { |
| 185 | - $this->_webroot = realpath(realpath($this->basePath) . DIRECTORY_SEPARATOR . $this->webrootDirectory); |
|
| 185 | + $this->_webroot = realpath(realpath($this->basePath).DIRECTORY_SEPARATOR.$this->webrootDirectory); |
|
| 186 | 186 | } |
| 187 | 187 | |
| 188 | 188 | return $this->_webroot; |