@@ -24,7 +24,7 @@ |
||
24 | 24 | 'name' => 'General', |
25 | 25 | 'description' => 'Script Tags', |
26 | 26 | 'handle' => ScriptService::GENERAL_HANDLE, |
27 | - 'class' => (string)MetaScriptContainer::class, |
|
27 | + 'class' => (string) MetaScriptContainer::class, |
|
28 | 28 | 'include' => true, |
29 | 29 | 'dependencies' => [ |
30 | 30 | ], |
@@ -24,7 +24,7 @@ |
||
24 | 24 | 'name' => 'General', |
25 | 25 | 'description' => 'Link Tags', |
26 | 26 | 'handle' => LinkService::GENERAL_HANDLE, |
27 | - 'class' => (string)MetaLinkContainer::class, |
|
27 | + 'class' => (string) MetaLinkContainer::class, |
|
28 | 28 | 'include' => true, |
29 | 29 | 'dependencies' => [ |
30 | 30 | ], |
@@ -24,7 +24,7 @@ discard block |
||
24 | 24 | 'name' => 'General', |
25 | 25 | 'description' => 'General Meta Tags', |
26 | 26 | 'handle' => TagService::GENERAL_HANDLE, |
27 | - 'class' => (string)MetaTagContainer::class, |
|
27 | + 'class' => (string) MetaTagContainer::class, |
|
28 | 28 | 'include' => true, |
29 | 29 | 'dependencies' => [ |
30 | 30 | ], |
@@ -35,7 +35,7 @@ discard block |
||
35 | 35 | 'name' => 'Facebook', |
36 | 36 | 'description' => 'Facebook OpenGraph Meta Tags', |
37 | 37 | 'handle' => TagService::FACEBOOK_HANDLE, |
38 | - 'class' => (string)MetaTagContainer::class, |
|
38 | + 'class' => (string) MetaTagContainer::class, |
|
39 | 39 | 'include' => true, |
40 | 40 | 'dependencies' => [ |
41 | 41 | ], |
@@ -46,7 +46,7 @@ discard block |
||
46 | 46 | 'name' => 'Twitter', |
47 | 47 | 'description' => 'Twitter Card Meta Tags', |
48 | 48 | 'handle' => TagService::TWITTER_HANDLE, |
49 | - 'class' => (string)MetaTagContainer::class, |
|
49 | + 'class' => (string) MetaTagContainer::class, |
|
50 | 50 | 'include' => true, |
51 | 51 | 'dependencies' => [ |
52 | 52 | ], |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | 'name' => 'Miscellaneous', |
58 | 58 | 'description' => 'Miscellaneous Meta Tags', |
59 | 59 | 'handle' => TagService::MISC_HANDLE, |
60 | - 'class' => (string)MetaTagContainer::class, |
|
60 | + 'class' => (string) MetaTagContainer::class, |
|
61 | 61 | 'include' => true, |
62 | 62 | 'dependencies' => [ |
63 | 63 | ], |
@@ -103,7 +103,7 @@ discard block |
||
103 | 103 | // Query the db table |
104 | 104 | $offset = ($page - 1) * $per_page; |
105 | 105 | $currentSiteHandle = ''; |
106 | - if ((int)$siteId !== 0) { |
|
106 | + if ((int) $siteId !== 0) { |
|
107 | 107 | $site = Craft::$app->getSites()->getSiteById($siteId); |
108 | 108 | if ($site !== null) { |
109 | 109 | $currentSiteHandle = $site->handle; |
@@ -158,11 +158,11 @@ discard block |
||
158 | 158 | $numGrades = \count(SettingsController::SETUP_GRADES); |
159 | 159 | $numFields = \count(SettingsController::SEO_SETUP_FIELDS); |
160 | 160 | foreach (SettingsController::SEO_SETUP_FIELDS as $setupField => $setupLabel) { |
161 | - $stat += (int)!empty($metaBundle->metaGlobalVars[$setupField]); |
|
161 | + $stat += (int) !empty($metaBundle->metaGlobalVars[$setupField]); |
|
162 | 162 | $value = $variables['contentSetupChecklist'][$setupField]['value'] ?? 0; |
163 | 163 | $variables['contentSetupChecklist'][$setupField] = [ |
164 | 164 | 'label' => $setupLabel, |
165 | - 'value' => $value + (int)!empty($metaBundle->metaGlobalVars[$setupField]), |
|
165 | + 'value' => $value + (int) !empty($metaBundle->metaGlobalVars[$setupField]), |
|
166 | 166 | ]; |
167 | 167 | } |
168 | 168 | $stat = round($numGrades - (($stat * $numGrades) / $numFields)); |
@@ -66,8 +66,8 @@ |
||
66 | 66 | string $sort = 'sourceName|asc', |
67 | 67 | int $page = 1, |
68 | 68 | int $per_page = 20, |
69 | - $filter = '', |
|
70 | - $siteId = 0 |
|
69 | + $filter = '', |
|
70 | + $siteId = 0 |
|
71 | 71 | ): Response |
72 | 72 | { |
73 | 73 | $data = []; |
@@ -71,7 +71,7 @@ |
||
71 | 71 | $serializedNonces = implode(" ", $cspNonces); |
72 | 72 | $cspDirective = self::CSP_DIRECTIVE; |
73 | 73 | $cspValue = "{$cspDirective} {$serializedNonces};"; |
74 | - foreach(self::CSP_HEADERS as $cspHeader) { |
|
74 | + foreach (self::CSP_HEADERS as $cspHeader) { |
|
75 | 75 | Craft::$app->getResponse()->getHeaders()->add($cspHeader, $cspValue); |
76 | 76 | } |
77 | 77 | } |
@@ -5,12 +5,12 @@ |
||
5 | 5 | ini_set('date.timezone', 'UTC'); |
6 | 6 | |
7 | 7 | // Use the current installation of Craft |
8 | -define('CRAFT_STORAGE_PATH', __DIR__ . '/_craft/storage'); |
|
9 | -define('CRAFT_TEMPLATES_PATH', __DIR__ . '/_craft/templates'); |
|
10 | -define('CRAFT_CONFIG_PATH', __DIR__ . '/_craft/config'); |
|
11 | -define('CRAFT_MIGRATIONS_PATH', __DIR__ . '/_craft/migrations'); |
|
12 | -define('CRAFT_TRANSLATIONS_PATH', __DIR__ . '/_craft/translations'); |
|
13 | -define('CRAFT_VENDOR_PATH', dirname(__DIR__) . '/vendor'); |
|
8 | +define('CRAFT_STORAGE_PATH', __DIR__.'/_craft/storage'); |
|
9 | +define('CRAFT_TEMPLATES_PATH', __DIR__.'/_craft/templates'); |
|
10 | +define('CRAFT_CONFIG_PATH', __DIR__.'/_craft/config'); |
|
11 | +define('CRAFT_MIGRATIONS_PATH', __DIR__.'/_craft/migrations'); |
|
12 | +define('CRAFT_TRANSLATIONS_PATH', __DIR__.'/_craft/translations'); |
|
13 | +define('CRAFT_VENDOR_PATH', dirname(__DIR__).'/vendor'); |
|
14 | 14 | define('CRAFT_TESTS_PATH', __DIR__); |
15 | 15 | |
16 | 16 | $devMode = true; |
@@ -56,7 +56,7 @@ |
||
56 | 56 | } |
57 | 57 | $tagData = $cache->getOrSet( |
58 | 58 | self::CONTAINER_TYPE.$uniqueKey, |
59 | - function () use ($uniqueKey) { |
|
59 | + function() use ($uniqueKey) { |
|
60 | 60 | Craft::info( |
61 | 61 | self::CONTAINER_TYPE.' cache miss: '.$uniqueKey, |
62 | 62 | __METHOD__ |
@@ -132,7 +132,7 @@ |
||
132 | 132 | ], |
133 | 133 | ]); |
134 | 134 | |
135 | - return $cache->getOrSet(self::CACHE_KEY.$groupId.self::CUSTOM_SCOPE.$handle.$siteId, function () use ( |
|
135 | + return $cache->getOrSet(self::CACHE_KEY.$groupId.self::CUSTOM_SCOPE.$handle.$siteId, function() use ( |
|
136 | 136 | $handle, |
137 | 137 | $siteId |
138 | 138 | ) { |
@@ -56,7 +56,7 @@ |
||
56 | 56 | } |
57 | 57 | $tagData = $cache->getOrSet( |
58 | 58 | self::CONTAINER_TYPE.$uniqueKey, |
59 | - function () use ($uniqueKey) { |
|
59 | + function() use ($uniqueKey) { |
|
60 | 60 | Craft::info( |
61 | 61 | self::CONTAINER_TYPE.' cache miss: '.$uniqueKey, |
62 | 62 | __METHOD__ |