@@ -357,7 +357,7 @@ discard block |
||
357 | 357 | $lastSegment = end($segments); |
358 | 358 | $site = Craft::$app->getSites()->getSiteByHandle($lastSegment); |
359 | 359 | if ($site !== null) { |
360 | - $siteSuffix = '/' . $lastSegment; |
|
360 | + $siteSuffix = '/'.$lastSegment; |
|
361 | 361 | } |
362 | 362 | } |
363 | 363 | $currentUser = Craft::$app->getUser()->getIdentity(); |
@@ -365,31 +365,31 @@ discard block |
||
365 | 365 | if ($currentUser->can('seomatic:dashboard')) { |
366 | 366 | $subNavs['dashboard'] = [ |
367 | 367 | 'label' => Craft::t('seomatic', 'Dashboard'), |
368 | - 'url' => 'seomatic/dashboard' . $siteSuffix, |
|
368 | + 'url' => 'seomatic/dashboard'.$siteSuffix, |
|
369 | 369 | ]; |
370 | 370 | } |
371 | 371 | if ($currentUser->can('seomatic:global-meta')) { |
372 | 372 | $subNavs['global'] = [ |
373 | 373 | 'label' => Craft::t('seomatic', 'Global SEO'), |
374 | - 'url' => 'seomatic/global/general' . $siteSuffix, |
|
374 | + 'url' => 'seomatic/global/general'.$siteSuffix, |
|
375 | 375 | ]; |
376 | 376 | } |
377 | 377 | if ($currentUser->can('seomatic:content-meta')) { |
378 | 378 | $subNavs['content'] = [ |
379 | 379 | 'label' => Craft::t('seomatic', 'Content SEO'), |
380 | - 'url' => 'seomatic/content' . $siteSuffix, |
|
380 | + 'url' => 'seomatic/content'.$siteSuffix, |
|
381 | 381 | ]; |
382 | 382 | } |
383 | 383 | if ($currentUser->can('seomatic:site-settings')) { |
384 | 384 | $subNavs['site'] = [ |
385 | 385 | 'label' => Craft::t('seomatic', 'Site Settings'), |
386 | - 'url' => 'seomatic/site/identity' . $siteSuffix, |
|
386 | + 'url' => 'seomatic/site/identity'.$siteSuffix, |
|
387 | 387 | ]; |
388 | 388 | } |
389 | 389 | if ($currentUser->can('seomatic:tracking-scripts')) { |
390 | 390 | $subNavs['tracking'] = [ |
391 | 391 | 'label' => Craft::t('seomatic', 'Tracking Scripts'), |
392 | - 'url' => 'seomatic/tracking/gtag' . $siteSuffix, |
|
392 | + 'url' => 'seomatic/tracking/gtag'.$siteSuffix, |
|
393 | 393 | ]; |
394 | 394 | } |
395 | 395 | $editableSettings = true; |
@@ -591,14 +591,14 @@ discard block |
||
591 | 591 | $element = $e->sender; |
592 | 592 | if ($element->uri !== null) { |
593 | 593 | $e->previewTargets[] = [ |
594 | - 'label' => ' |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | /** |
90 | 90 | * @inheritdoc |
91 | 91 | */ |
92 | - protected array|bool|int $allowAnonymous = [ |
|
92 | + protected array | bool | int $allowAnonymous = [ |
|
93 | 93 | ]; |
94 | 94 | |
95 | 95 | // Public Methods |
@@ -133,7 +133,7 @@ discard block |
||
133 | 133 | $variables['pluginName'] = Seomatic::$settings->pluginName; |
134 | 134 | $variables['title'] = $templateTitle; |
135 | 135 | $variables['docTitle'] = "{$pluginName} - {$templateTitle}"; |
136 | - $siteHandleUri = Craft::$app->isMultiSite ? '/' . $siteHandle : ''; |
|
136 | + $siteHandleUri = Craft::$app->isMultiSite ? '/'.$siteHandle : ''; |
|
137 | 137 | $variables['crumbs'] = [ |
138 | 138 | [ |
139 | 139 | 'label' => $pluginName, |
@@ -141,7 +141,7 @@ discard block |
||
141 | 141 | ], |
142 | 142 | [ |
143 | 143 | 'label' => $templateTitle, |
144 | - 'url' => UrlHelper::cpUrl('seomatic/dashboard' . $siteHandleUri), |
|
144 | + 'url' => UrlHelper::cpUrl('seomatic/dashboard'.$siteHandleUri), |
|
145 | 145 | ], |
146 | 146 | ]; |
147 | 147 | $variables['selectedSubnavItem'] = 'dashboard'; |
@@ -164,11 +164,11 @@ discard block |
||
164 | 164 | foreach ($variables['metaBundles'] as $metaBundle) { |
165 | 165 | $stat = 0; |
166 | 166 | foreach (self::SEO_SETUP_FIELDS as $setupField => $setupLabel) { |
167 | - $stat += (int)!empty($metaBundle->metaGlobalVars[$setupField]); |
|
167 | + $stat += (int) !empty($metaBundle->metaGlobalVars[$setupField]); |
|
168 | 168 | $value = $variables['contentSetupChecklist'][$setupField]['value'] ?? 0; |
169 | 169 | $variables['contentSetupChecklist'][$setupField] = [ |
170 | 170 | 'label' => $setupLabel, |
171 | - 'value' => $value + (int)!empty($metaBundle->metaGlobalVars[$setupField]), |
|
171 | + 'value' => $value + (int) !empty($metaBundle->metaGlobalVars[$setupField]), |
|
172 | 172 | ]; |
173 | 173 | } |
174 | 174 | $stat = round($numGrades - (($stat * $numGrades) / $numFields)); |
@@ -179,16 +179,16 @@ discard block |
||
179 | 179 | } |
180 | 180 | // Global SEO grades |
181 | 181 | Seomatic::$previewingMetaContainers = true; |
182 | - $metaBundle = Seomatic::$plugin->metaBundles->getGlobalMetaBundle((int)$siteId); |
|
182 | + $metaBundle = Seomatic::$plugin->metaBundles->getGlobalMetaBundle((int) $siteId); |
|
183 | 183 | Seomatic::$previewingMetaContainers = false; |
184 | 184 | if ($metaBundle !== null) { |
185 | 185 | $stat = 0; |
186 | 186 | $variables['globalSetupChecklist'] = []; |
187 | 187 | foreach (self::SEO_SETUP_FIELDS as $setupField => $setupLabel) { |
188 | - $stat += (int)!empty($metaBundle->metaGlobalVars[$setupField]); |
|
188 | + $stat += (int) !empty($metaBundle->metaGlobalVars[$setupField]); |
|
189 | 189 | $variables['globalSetupChecklist'][$setupField] = [ |
190 | 190 | 'label' => $setupLabel, |
191 | - 'value' => (int)!empty($metaBundle->metaGlobalVars[$setupField]), |
|
191 | + 'value' => (int) !empty($metaBundle->metaGlobalVars[$setupField]), |
|
192 | 192 | ]; |
193 | 193 | } |
194 | 194 | $stat = round(($stat / $numFields) * 100); |
@@ -198,17 +198,17 @@ discard block |
||
198 | 198 | $stat = 0; |
199 | 199 | $variables['siteSetupChecklist'] = []; |
200 | 200 | foreach (self::SITE_SETUP_FIELDS as $setupField => $setupLabel) { |
201 | - $stat += (int)!empty($metaBundle->metaSiteVars[$setupField]); |
|
201 | + $stat += (int) !empty($metaBundle->metaSiteVars[$setupField]); |
|
202 | 202 | $variables['siteSetupChecklist'][$setupField] = [ |
203 | 203 | 'label' => $setupLabel, |
204 | - 'value' => (int)!empty($metaBundle->metaSiteVars[$setupField]), |
|
204 | + 'value' => (int) !empty($metaBundle->metaSiteVars[$setupField]), |
|
205 | 205 | ]; |
206 | 206 | } |
207 | 207 | foreach (self::IDENTITY_SETUP_FIELDS as $setupField => $setupLabel) { |
208 | - $stat += (int)!empty($metaBundle->metaSiteVars->identity[$setupField]); |
|
208 | + $stat += (int) !empty($metaBundle->metaSiteVars->identity[$setupField]); |
|
209 | 209 | $variables['siteSetupChecklist'][$setupField] = [ |
210 | 210 | 'label' => $setupLabel, |
211 | - 'value' => (int)!empty($metaBundle->metaSiteVars->identity[$setupField]), |
|
211 | + 'value' => (int) !empty($metaBundle->metaSiteVars->identity[$setupField]), |
|
212 | 212 | ]; |
213 | 213 | } |
214 | 214 | $stat = round(($stat / $numFields) * 100); |
@@ -256,7 +256,7 @@ discard block |
||
256 | 256 | $variables['title'] = $templateTitle; |
257 | 257 | $variables['subSectionTitle'] = $subSectionTitle; |
258 | 258 | $variables['docTitle'] = "{$pluginName} - {$templateTitle} - {$subSectionTitle}"; |
259 | - $siteHandleUri = Craft::$app->isMultiSite ? '/' . $siteHandle : ''; |
|
259 | + $siteHandleUri = Craft::$app->isMultiSite ? '/'.$siteHandle : ''; |
|
260 | 260 | $variables['crumbs'] = [ |
261 | 261 | [ |
262 | 262 | 'label' => $pluginName, |
@@ -264,11 +264,11 @@ discard block |
||
264 | 264 | ], |
265 | 265 | [ |
266 | 266 | 'label' => $templateTitle, |
267 | - 'url' => UrlHelper::cpUrl('seomatic/global/general' . $siteHandleUri), |
|
267 | + 'url' => UrlHelper::cpUrl('seomatic/global/general'.$siteHandleUri), |
|
268 | 268 | ], |
269 | 269 | [ |
270 | 270 | 'label' => $subSectionTitle, |
271 | - 'url' => UrlHelper::cpUrl('seomatic/global/' . $subSection . $siteHandleUri), |
|
271 | + 'url' => UrlHelper::cpUrl('seomatic/global/'.$subSection.$siteHandleUri), |
|
272 | 272 | ], |
273 | 273 | ]; |
274 | 274 | $variables['selectedSubnavItem'] = 'global'; |
@@ -276,14 +276,14 @@ discard block |
||
276 | 276 | $this->setGlobalFieldSourceVariables($variables); |
277 | 277 | // Enabled sites |
278 | 278 | $this->setMultiSiteVariables($siteHandle, $siteId, $variables); |
279 | - $variables['controllerHandle'] = 'global' . '/' . $subSection; |
|
279 | + $variables['controllerHandle'] = 'global'.'/'.$subSection; |
|
280 | 280 | $variables['currentSubSection'] = $subSection; |
281 | 281 | // Meta bundle settings |
282 | 282 | Seomatic::$previewingMetaContainers = true; |
283 | 283 | // Get the site to copy the settings from, if any |
284 | 284 | $variables['loadFromSiteHandle'] = $loadFromSiteHandle; |
285 | 285 | $loadFromSiteId = $this->getSiteIdFromHandle($loadFromSiteHandle); |
286 | - $siteIdToLoad = $loadFromSiteHandle === null ? (int)$variables['currentSiteId'] : $loadFromSiteId; |
|
286 | + $siteIdToLoad = $loadFromSiteHandle === null ? (int) $variables['currentSiteId'] : $loadFromSiteId; |
|
287 | 287 | // Load the metabundle |
288 | 288 | $metaBundle = Seomatic::$plugin->metaBundles->getGlobalMetaBundle($siteIdToLoad); |
289 | 289 | if ($editedMetaBundle) { |
@@ -338,11 +338,11 @@ discard block |
||
338 | 338 | // Preview the meta containers |
339 | 339 | Seomatic::$plugin->metaContainers->previewMetaContainers( |
340 | 340 | MetaBundles::GLOBAL_META_BUNDLE, |
341 | - (int)$variables['currentSiteId'] |
|
341 | + (int) $variables['currentSiteId'] |
|
342 | 342 | ); |
343 | 343 | |
344 | 344 | // Render the template |
345 | - return $this->renderTemplate('seomatic/settings/global/' . $subSection, $variables); |
|
345 | + return $this->renderTemplate('seomatic/settings/global/'.$subSection, $variables); |
|
346 | 346 | } |
347 | 347 | |
348 | 348 | /** |
@@ -474,7 +474,7 @@ discard block |
||
474 | 474 | $variables['pluginName'] = Seomatic::$settings->pluginName; |
475 | 475 | $variables['title'] = $templateTitle; |
476 | 476 | $variables['docTitle'] = "{$pluginName} - {$templateTitle}"; |
477 | - $siteHandleUri = Craft::$app->isMultiSite ? '/' . $siteHandle : ''; |
|
477 | + $siteHandleUri = Craft::$app->isMultiSite ? '/'.$siteHandle : ''; |
|
478 | 478 | $variables['crumbs'] = [ |
479 | 479 | [ |
480 | 480 | 'label' => $pluginName, |
@@ -482,7 +482,7 @@ discard block |
||
482 | 482 | ], |
483 | 483 | [ |
484 | 484 | 'label' => $templateTitle, |
485 | - 'url' => UrlHelper::cpUrl('seomatic/content' . $siteHandleUri), |
|
485 | + 'url' => UrlHelper::cpUrl('seomatic/content'.$siteHandleUri), |
|
486 | 486 | ], |
487 | 487 | ]; |
488 | 488 | $this->setMultiSiteVariables($siteHandle, $siteId, $variables); |
@@ -523,7 +523,7 @@ discard block |
||
523 | 523 | $siteHandle = $this->getCpSiteHandle($siteHandle); |
524 | 524 | $siteId = $this->getSiteIdFromHandle($siteHandle); |
525 | 525 | if (is_string($typeId)) { |
526 | - $typeId = (int)$typeId; |
|
526 | + $typeId = (int) $typeId; |
|
527 | 527 | } |
528 | 528 | if (empty($typeId)) { |
529 | 529 | $typeId = null; |
@@ -541,7 +541,7 @@ discard block |
||
541 | 541 | $currentType = reset($typeMenu); |
542 | 542 | $variables['currentType'] = $typeMenu[$typeId] ?? $currentType; |
543 | 543 | $variables['currentTypeId'] = $typeId ?? key($typeMenu); |
544 | - $typeId = (int)$variables['currentTypeId']; |
|
544 | + $typeId = (int) $variables['currentTypeId']; |
|
545 | 545 | } |
546 | 546 | // If there's only one EntryType, don't bother displaying the menu |
547 | 547 | if (count($typeMenu) === 1) { |
@@ -573,7 +573,7 @@ discard block |
||
573 | 573 | // Get the site to copy the settings from, if any |
574 | 574 | $variables['loadFromSiteHandle'] = $loadFromSiteHandle; |
575 | 575 | $loadFromSiteId = $this->getSiteIdFromHandle($loadFromSiteHandle); |
576 | - $siteIdToLoad = $loadFromSiteHandle === null ? (int)$variables['currentSiteId'] : $loadFromSiteId; |
|
576 | + $siteIdToLoad = $loadFromSiteHandle === null ? (int) $variables['currentSiteId'] : $loadFromSiteId; |
|
577 | 577 | // Load the metabundle |
578 | 578 | $metaBundle = Seomatic::$plugin->metaBundles->getMetaBundleBySourceHandle( |
579 | 579 | $sourceBundleType, |
@@ -599,7 +599,7 @@ discard block |
||
599 | 599 | $variables['title'] = $templateTitle; |
600 | 600 | $variables['subSectionTitle'] = $subSectionTitle; |
601 | 601 | $variables['docTitle'] = "{$pluginName} - Content SEO - {$templateTitle} - {$subSectionTitle}"; |
602 | - $siteHandleUri = Craft::$app->isMultiSite ? '/' . $siteHandle : ''; |
|
602 | + $siteHandleUri = Craft::$app->isMultiSite ? '/'.$siteHandle : ''; |
|
603 | 603 | $variables['siteHandleUri'] = $siteHandleUri; |
604 | 604 | $variables['crumbs'] = [ |
605 | 605 | [ |
@@ -608,10 +608,10 @@ discard block |
||
608 | 608 | ], |
609 | 609 | [ |
610 | 610 | 'label' => 'Content SEO', |
611 | - 'url' => UrlHelper::cpUrl('seomatic/content' . $siteHandleUri), |
|
611 | + 'url' => UrlHelper::cpUrl('seomatic/content'.$siteHandleUri), |
|
612 | 612 | ], |
613 | 613 | [ |
614 | - 'label' => $metaBundle->sourceName . ' · ' . $subSectionTitle, |
|
614 | + 'label' => $metaBundle->sourceName.' · '.$subSectionTitle, |
|
615 | 615 | 'url' => UrlHelper::cpUrl("seomatic/edit-content/${subSection}/${sourceBundleType}/${sourceHandle}"), |
616 | 616 | ], |
617 | 617 | ]; |
@@ -642,13 +642,13 @@ discard block |
||
642 | 642 | // Preview the meta containers |
643 | 643 | Seomatic::$plugin->metaContainers->previewMetaContainers( |
644 | 644 | $uri, |
645 | - (int)$variables['currentSiteId'], |
|
645 | + (int) $variables['currentSiteId'], |
|
646 | 646 | false, |
647 | 647 | false |
648 | 648 | ); |
649 | 649 | |
650 | 650 | // Render the template |
651 | - return $this->renderTemplate('seomatic/settings/content/' . $subSection, $variables); |
|
651 | + return $this->renderTemplate('seomatic/settings/content/'.$subSection, $variables); |
|
652 | 652 | } |
653 | 653 | |
654 | 654 | /** |
@@ -669,7 +669,7 @@ discard block |
||
669 | 669 | $bundleSettings = $request->getParam('metaBundleSettings'); |
670 | 670 | $sitemapSettings = $request->getParam('metaSitemapVars'); |
671 | 671 | if (is_string($typeId)) { |
672 | - $typeId = (int)$typeId; |
|
672 | + $typeId = (int) $typeId; |
|
673 | 673 | } |
674 | 674 | // Set the element type in the template |
675 | 675 | $elementName = ''; |
@@ -741,7 +741,7 @@ discard block |
||
741 | 741 | if ($subSection === 'social') { |
742 | 742 | $subSectionSuffix = ' Media'; |
743 | 743 | } |
744 | - $subSectionTitle = Craft::t('seomatic', ucfirst($subSection) . $subSectionSuffix); |
|
744 | + $subSectionTitle = Craft::t('seomatic', ucfirst($subSection).$subSectionSuffix); |
|
745 | 745 | // Asset bundle |
746 | 746 | try { |
747 | 747 | Seomatic::$view->registerAssetBundle(SeomaticAsset::class); |
@@ -759,7 +759,7 @@ discard block |
||
759 | 759 | $variables['title'] = $templateTitle; |
760 | 760 | $variables['subSectionTitle'] = $subSectionTitle; |
761 | 761 | $variables['docTitle'] = "{$pluginName} - {$templateTitle} - {$subSectionTitle}"; |
762 | - $siteHandleUri = Craft::$app->isMultiSite ? '/' . $siteHandle : ''; |
|
762 | + $siteHandleUri = Craft::$app->isMultiSite ? '/'.$siteHandle : ''; |
|
763 | 763 | $variables['crumbs'] = [ |
764 | 764 | [ |
765 | 765 | 'label' => $pluginName, |
@@ -767,11 +767,11 @@ discard block |
||
767 | 767 | ], |
768 | 768 | [ |
769 | 769 | 'label' => $templateTitle, |
770 | - 'url' => UrlHelper::cpUrl('seomatic/site/identity' . $siteHandleUri), |
|
770 | + 'url' => UrlHelper::cpUrl('seomatic/site/identity'.$siteHandleUri), |
|
771 | 771 | ], |
772 | 772 | [ |
773 | 773 | 'label' => $subSectionTitle, |
774 | - 'url' => UrlHelper::cpUrl('seomatic/site/' . $subSection . $siteHandleUri), |
|
774 | + 'url' => UrlHelper::cpUrl('seomatic/site/'.$subSection.$siteHandleUri), |
|
775 | 775 | ], |
776 | 776 | ]; |
777 | 777 | $variables['selectedSubnavItem'] = 'site'; |
@@ -779,14 +779,14 @@ discard block |
||
779 | 779 | |
780 | 780 | // Enabled sites |
781 | 781 | $this->setMultiSiteVariables($siteHandle, $siteId, $variables); |
782 | - $variables['controllerHandle'] = 'site' . '/' . $subSection; |
|
782 | + $variables['controllerHandle'] = 'site'.'/'.$subSection; |
|
783 | 783 | |
784 | 784 | // The site settings for the appropriate meta bundle |
785 | 785 | Seomatic::$previewingMetaContainers = true; |
786 | 786 | // Get the site to copy the settings from, if any |
787 | 787 | $variables['loadFromSiteHandle'] = $loadFromSiteHandle; |
788 | 788 | $loadFromSiteId = $this->getSiteIdFromHandle($loadFromSiteHandle); |
789 | - $siteIdToLoad = $loadFromSiteHandle === null ? (int)$variables['currentSiteId'] : $loadFromSiteId; |
|
789 | + $siteIdToLoad = $loadFromSiteHandle === null ? (int) $variables['currentSiteId'] : $loadFromSiteId; |
|
790 | 790 | // Load the metabundle |
791 | 791 | $metaBundle = Seomatic::$plugin->metaBundles->getGlobalMetaBundle($siteIdToLoad); |
792 | 792 | Seomatic::$previewingMetaContainers = false; |
@@ -805,7 +805,7 @@ discard block |
||
805 | 805 | $variables['assetVolumeSources'] = AssetHelper::getAssetInputSources(); |
806 | 806 | |
807 | 807 | // Render the template |
808 | - return $this->renderTemplate('seomatic/settings/site/' . $subSection, $variables); |
|
808 | + return $this->renderTemplate('seomatic/settings/site/'.$subSection, $variables); |
|
809 | 809 | } |
810 | 810 | |
811 | 811 | /** |
@@ -937,7 +937,7 @@ discard block |
||
937 | 937 | $siteId = $this->getSiteIdFromHandle($siteHandle); |
938 | 938 | // Enabled sites |
939 | 939 | $this->setMultiSiteVariables($siteHandle, $siteId, $variables); |
940 | - $variables['controllerHandle'] = 'tracking' . '/' . $subSection; |
|
940 | + $variables['controllerHandle'] = 'tracking'.'/'.$subSection; |
|
941 | 941 | $variables['currentSubSection'] = $subSection; |
942 | 942 | |
943 | 943 | // The script meta containers for the global meta bundle |
@@ -945,7 +945,7 @@ discard block |
||
945 | 945 | // Get the site to copy the settings from, if any |
946 | 946 | $variables['loadFromSiteHandle'] = $loadFromSiteHandle; |
947 | 947 | $loadFromSiteId = $this->getSiteIdFromHandle($loadFromSiteHandle); |
948 | - $siteIdToLoad = $loadFromSiteHandle === null ? (int)$variables['currentSiteId'] : $loadFromSiteId; |
|
948 | + $siteIdToLoad = $loadFromSiteHandle === null ? (int) $variables['currentSiteId'] : $loadFromSiteId; |
|
949 | 949 | // Load the metabundle |
950 | 950 | $metaBundle = Seomatic::$plugin->metaBundles->getGlobalMetaBundle($siteIdToLoad); |
951 | 951 | if ($editedMetaBundle) { |
@@ -985,7 +985,7 @@ discard block |
||
985 | 985 | $variables['title'] = $templateTitle; |
986 | 986 | $variables['subSectionTitle'] = $subSectionTitle; |
987 | 987 | $variables['docTitle'] = "{$pluginName} - {$templateTitle} - {$subSectionTitle}"; |
988 | - $siteHandleUri = Craft::$app->isMultiSite ? '/' . $siteHandle : ''; |
|
988 | + $siteHandleUri = Craft::$app->isMultiSite ? '/'.$siteHandle : ''; |
|
989 | 989 | $variables['crumbs'] = [ |
990 | 990 | [ |
991 | 991 | 'label' => $pluginName, |
@@ -997,7 +997,7 @@ discard block |
||
997 | 997 | ], |
998 | 998 | [ |
999 | 999 | 'label' => $subSectionTitle, |
1000 | - 'url' => UrlHelper::cpUrl('seomatic/tracking/' . $subSection . $siteHandleUri), |
|
1000 | + 'url' => UrlHelper::cpUrl('seomatic/tracking/'.$subSection.$siteHandleUri), |
|
1001 | 1001 | ], |
1002 | 1002 | ]; |
1003 | 1003 | $variables['selectedSubnavItem'] = 'tracking'; |
@@ -1150,7 +1150,7 @@ discard block |
||
1150 | 1150 | if ($siteHandle !== null) { |
1151 | 1151 | $site = Craft::$app->getSites()->getSiteByHandle($siteHandle); |
1152 | 1152 | if (!$site) { |
1153 | - throw new NotFoundHttpException('Invalid site handle: ' . $siteHandle); |
|
1153 | + throw new NotFoundHttpException('Invalid site handle: '.$siteHandle); |
|
1154 | 1154 | } |
1155 | 1155 | $siteId = $site->id; |
1156 | 1156 | } else { |
@@ -1187,7 +1187,7 @@ discard block |
||
1187 | 1187 | if (!empty($variables['enabledSiteIds'])) { |
1188 | 1188 | $siteId = reset($variables['enabledSiteIds']); |
1189 | 1189 | } else { |
1190 | - $this->requirePermission('editSite:' . $siteId); |
|
1190 | + $this->requirePermission('editSite:'.$siteId); |
|
1191 | 1191 | } |
1192 | 1192 | } |
1193 | 1193 | } |
@@ -1207,7 +1207,7 @@ discard block |
||
1207 | 1207 | if ($variables['showSites']) { |
1208 | 1208 | $variables['sitesMenuLabel'] = Craft::t( |
1209 | 1209 | 'site', |
1210 | - $sites->getSiteById((int)$variables['currentSiteId'])->name |
|
1210 | + $sites->getSiteById((int) $variables['currentSiteId'])->name |
|
1211 | 1211 | ); |
1212 | 1212 | } else { |
1213 | 1213 | $variables['sitesMenuLabel'] = ''; |
@@ -1274,7 +1274,7 @@ discard block |
||
1274 | 1274 | $typeId = null, |
1275 | 1275 | ) { |
1276 | 1276 | $variables['textFieldSources'] = array_merge( |
1277 | - ['entryGroup' => ['optgroup' => $groupName . ' Fields'], 'title' => 'Title'], |
|
1277 | + ['entryGroup' => ['optgroup' => $groupName.' Fields'], 'title' => 'Title'], |
|
1278 | 1278 | FieldHelper::fieldsOfTypeFromSource( |
1279 | 1279 | $sourceBundleType, |
1280 | 1280 | $sourceHandle, |
@@ -1284,7 +1284,7 @@ discard block |
||
1284 | 1284 | ) |
1285 | 1285 | ); |
1286 | 1286 | $variables['assetFieldSources'] = array_merge( |
1287 | - ['entryGroup' => ['optgroup' => $groupName . ' Fields']], |
|
1287 | + ['entryGroup' => ['optgroup' => $groupName.' Fields']], |
|
1288 | 1288 | FieldHelper::fieldsOfTypeFromSource( |
1289 | 1289 | $sourceBundleType, |
1290 | 1290 | $sourceHandle, |