@@ -43,14 +43,14 @@ discard block |
||
43 | 43 | // SEO |
44 | 44 | $route = Url::toRoute(Yii::$app->controller->action->uniqueId); |
45 | 45 | if ($keywords = \Yii::$app->settings->get($route, 'app.seo.keywords', null)) { |
46 | - $this->registerMetaTag(['name' => 'keywords', 'content' => $keywords]); |
|
46 | + $this->registerMetaTag([ 'name' => 'keywords', 'content' => $keywords ]); |
|
47 | 47 | } |
48 | 48 | if ($description = \Yii::$app->settings->get($route, 'app.seo.descriptions', null)) { |
49 | - $this->registerMetaTag(['name' => 'description', 'content' => $description]); |
|
49 | + $this->registerMetaTag([ 'name' => 'description', 'content' => $description ]); |
|
50 | 50 | } |
51 | 51 | |
52 | 52 | if ($favicon = \Yii::$app->settings->get('faviconPng', 'app.assets', null)) { |
53 | - $this->registerLinkTag(['rel' => 'shortcut icon', 'type'=>'image/png', 'href' => $favicon]); |
|
53 | + $this->registerLinkTag([ 'rel' => 'shortcut icon', 'type'=>'image/png', 'href' => $favicon ]); |
|
54 | 54 | } |
55 | 55 | |
56 | 56 | ?> |
@@ -72,7 +72,7 @@ discard block |
||
72 | 72 | |
73 | 73 | <?php |
74 | 74 | if (Yii::$app->settings->get('enableTwigNavbar', 'app.layout', false)) { |
75 | - echo \dmstr\modules\prototype\widgets\TwigWidget::widget(['key' => '_navbar']); |
|
75 | + echo \dmstr\modules\prototype\widgets\TwigWidget::widget([ 'key' => '_navbar' ]); |
|
76 | 76 | } else { |
77 | 77 | echo $this->render('_navbar'); |
78 | 78 | } |
@@ -85,7 +85,7 @@ discard block |
||
85 | 85 | </div> |
86 | 86 | |
87 | 87 | <footer class="footer"> |
88 | - <?= Cell::widget(['id' => '_footer', 'requestParam' => '_global']) ?> |
|
88 | + <?= Cell::widget([ 'id' => '_footer', 'requestParam' => '_global' ]) ?> |
|
89 | 89 | </footer> |
90 | 90 | |
91 | 91 | <div class="phd-info" style="position: fixed; z-index: 1200; bottom: 0px; left: 10px; padding: 30px 0 0px; opacity: .3"> |
@@ -93,7 +93,7 @@ discard block |
||
93 | 93 | <?= Html::a( |
94 | 94 | '<i class="fa fa-heartbeat"></i>', |
95 | 95 | '#', |
96 | - ['class' => 'text-muted', 'data-toggle' => 'modal', 'data-target' => '#infoModal'] |
|
96 | + [ 'class' => 'text-muted', 'data-toggle' => 'modal', 'data-target' => '#infoModal' ] |
|
97 | 97 | ) ?> |
98 | 98 | </p> |
99 | 99 | </div> |
@@ -13,13 +13,13 @@ discard block |
||
13 | 13 | $languages = explode(',', getenv('APP_LANGUAGES')); |
14 | 14 | |
15 | 15 | // prepare asset bundle config |
16 | -$bundles = []; |
|
16 | +$bundles = [ ]; |
|
17 | 17 | if (getenv('APP_ASSET_USE_BUNDLED')) { |
18 | 18 | $bundles = include Yii::getAlias('@web/bundles').'/config.php'; |
19 | 19 | } |
20 | 20 | if (getenv('APP_ASSET_DISABLE_BOOTSTRAP_BUNDLE')) { |
21 | - $bundles['yii\bootstrap\BootstrapAsset'] = [ |
|
22 | - 'css' => [], |
|
21 | + $bundles[ 'yii\bootstrap\BootstrapAsset' ] = [ |
|
22 | + 'css' => [ ], |
|
23 | 23 | ]; |
24 | 24 | } |
25 | 25 | |
@@ -40,7 +40,7 @@ discard block |
||
40 | 40 | // Basic configuration, used in web and console applications |
41 | 41 | return [ |
42 | 42 | 'id' => 'app', |
43 | - 'language' => $languages[0], |
|
43 | + 'language' => $languages[ 0 ], |
|
44 | 44 | 'basePath' => realpath(__DIR__.'/..'), |
45 | 45 | 'vendorPath' => '@app/../vendor', |
46 | 46 | 'runtimePath' => '@app/../runtime', |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | ], |
55 | 55 | 'params' => [ |
56 | 56 | 'adminEmail' => getenv('APP_ADMIN_EMAIL'), |
57 | - 'context.menuItems' => [], |
|
57 | + 'context.menuItems' => [ ], |
|
58 | 58 | 'yii.migrations' => [ |
59 | 59 | getenv('APP_MIGRATION_LOOKUP'), |
60 | 60 | '@yii/rbac/migrations', |
@@ -72,8 +72,7 @@ discard block |
||
72 | 72 | 'dirMode' => 0775, |
73 | 73 | // Hashing for distributed systems |
74 | 74 | 'hashCallback' => YII_ENV_DEV ? |
75 | - null : |
|
76 | - function ($path) { |
|
75 | + null : function($path) { |
|
77 | 76 | return YII_ENV.'-'.substr(hash('sha256', $path), 0, 8).'-'.APP_VERSION.'-'.\Yii::$app->cache->get('prototype.less.changed_at'); |
78 | 77 | }, |
79 | 78 | // Note: You need to bundle asset with `yii asset` for development/debugging |
@@ -124,8 +123,8 @@ discard block |
||
124 | 123 | [ |
125 | 124 | 'class' => 'codemix\streamlog\Target', |
126 | 125 | 'url' => 'php://stderr', |
127 | - 'levels' => ['error', 'warning'], |
|
128 | - 'logVars' => [], |
|
126 | + 'levels' => [ 'error', 'warning' ], |
|
127 | + 'logVars' => [ ], |
|
129 | 128 | ], |
130 | 129 | ], |
131 | 130 | ], |
@@ -154,9 +153,9 @@ discard block |
||
154 | 153 | 'user' => [ |
155 | 154 | 'class' => 'dmstr\web\User', |
156 | 155 | 'enableAutoLogin' => true, |
157 | - 'loginUrl' => ['/user/security/login'], |
|
156 | + 'loginUrl' => [ '/user/security/login' ], |
|
158 | 157 | 'identityClass' => 'dektrium\user\models\User', |
159 | - 'rootUsers' => ['admin'], |
|
158 | + 'rootUsers' => [ 'admin' ], |
|
160 | 159 | ], |
161 | 160 | 'urlManager' => [ |
162 | 161 | 'class' => 'codemix\localeurls\UrlManager', |
@@ -164,7 +163,7 @@ discard block |
||
164 | 163 | 'showScriptName' => false, |
165 | 164 | 'enableDefaultLanguageUrlCode' => true, |
166 | 165 | 'baseUrl' => '/', |
167 | - 'rules' => [], |
|
166 | + 'rules' => [ ], |
|
168 | 167 | 'ignoreLanguageUrlPatterns' => [ |
169 | 168 | // route pattern => url pattern |
170 | 169 | '#^filefly/api#' => '#^filefly/api#', |
@@ -180,8 +179,8 @@ discard block |
||
180 | 179 | 'options' => [ |
181 | 180 | 'auto_reload' => true, |
182 | 181 | ], |
183 | - 'globals' => ['html' => '\yii\helpers\Html'], |
|
184 | - 'uses' => ['yii\bootstrap'], |
|
182 | + 'globals' => [ 'html' => '\yii\helpers\Html' ], |
|
183 | + 'uses' => [ 'yii\bootstrap' ], |
|
185 | 184 | ], |
186 | 185 | ], |
187 | 186 | ], |
@@ -202,9 +201,9 @@ discard block |
||
202 | 201 | // 'audit/config', |
203 | 202 | |
204 | 203 | // These provide special functionality and get loaded to activate it |
205 | - 'audit/error', // Links the extra error reporting functions (`exception()` and `errorMessage()`) |
|
206 | - 'audit/extra', // Links the data functions (`data()`) |
|
207 | - 'audit/curl', // Links the curl tracking function (`curlBegin()`, `curlEnd()` and `curlExec()`) |
|
204 | + 'audit/error', // Links the extra error reporting functions (`exception()` and `errorMessage()`) |
|
205 | + 'audit/extra', // Links the data functions (`data()`) |
|
206 | + 'audit/curl', // Links the curl tracking function (`curlBegin()`, `curlEnd()` and `curlExec()`) |
|
208 | 207 | ], |
209 | 208 | 'ignoreActions' => [ |
210 | 209 | 'audit/*', |
@@ -254,8 +253,8 @@ discard block |
||
254 | 253 | 'class' => 'lajax\translatemanager\Module', |
255 | 254 | 'root' => '@app/views', |
256 | 255 | 'layout' => '@backend/views/layouts/box', |
257 | - 'allowedIPs' => ['*'], |
|
258 | - 'roles' => ['translate-module'], |
|
256 | + 'allowedIPs' => [ '*' ], |
|
257 | + 'roles' => [ 'translate-module' ], |
|
259 | 258 | ], |
260 | 259 | 'user' => [ |
261 | 260 | 'class' => 'dektrium\user\Module', |