@@ -265,7 +265,7 @@ discard block |
||
265 | 265 | // Exclude some properties |
266 | 266 | $propertyAllowed = true; |
267 | 267 | foreach (self::EXCLUDED_PROPERTY_REGEXES as $excludePattern) { |
268 | - $pattern = '`' . $excludePattern . '`i'; |
|
268 | + $pattern = '`'.$excludePattern.'`i'; |
|
269 | 269 | if (preg_match($pattern, $propertyName) === 1) { |
270 | 270 | $propertyAllowed = false; |
271 | 271 | } |
@@ -341,7 +341,7 @@ discard block |
||
341 | 341 | 'kind' => $customField ? self::CompletionItemKind['Field'] : self::CompletionItemKind['Property'], |
342 | 342 | 'label' => $label, |
343 | 343 | 'insertText' => $label, |
344 | - 'sortText' => $sortPrefix . $label, |
|
344 | + 'sortText' => $sortPrefix.$label, |
|
345 | 345 | ] |
346 | 346 | ]); |
347 | 347 | // Recurse through if this is an object |
@@ -373,7 +373,7 @@ discard block |
||
373 | 373 | // Exclude some properties |
374 | 374 | $methodAllowed = true; |
375 | 375 | foreach (self::EXCLUDED_METHOD_REGEXES as $excludePattern) { |
376 | - $pattern = '`' . $excludePattern . '`i'; |
|
376 | + $pattern = '`'.$excludePattern.'`i'; |
|
377 | 377 | if (preg_match($pattern, $methodName) === 1) { |
378 | 378 | $methodAllowed = false; |
379 | 379 | } |
@@ -395,7 +395,7 @@ discard block |
||
395 | 395 | } |
396 | 396 | } |
397 | 397 | } |
398 | - $detail = $methodName . '('; |
|
398 | + $detail = $methodName.'('; |
|
399 | 399 | $params = $reflectionMethod->getParameters(); |
400 | 400 | $paramList = []; |
401 | 401 | foreach ($params as $param) { |
@@ -405,20 +405,20 @@ discard block |
||
405 | 405 | $unionTypes = $reflectionType->getTypes(); |
406 | 406 | $typeName = ''; |
407 | 407 | foreach ($unionTypes as $unionType) { |
408 | - $typeName .= '|' . $unionType->getName(); |
|
408 | + $typeName .= '|'.$unionType->getName(); |
|
409 | 409 | } |
410 | 410 | $typeName = trim($typeName, '|'); |
411 | - $paramList[] = $typeName . ': ' . '$' . $param->getName(); |
|
411 | + $paramList[] = $typeName.': '.'$'.$param->getName(); |
|
412 | 412 | } else { |
413 | - $paramList[] = $param->getType()->getName() . ': ' . '$' . $param->getName(); |
|
413 | + $paramList[] = $param->getType()->getName().': '.'$'.$param->getName(); |
|
414 | 414 | } |
415 | 415 | } else { |
416 | - $paramList[] = '$' . $param->getName(); |
|
416 | + $paramList[] = '$'.$param->getName(); |
|
417 | 417 | } |
418 | 418 | } |
419 | - $detail .= implode(', ', $paramList) . ')'; |
|
419 | + $detail .= implode(', ', $paramList).')'; |
|
420 | 420 | $thisPath = trim(implode('.', [$path, $methodName]), '.'); |
421 | - $label = $methodName . '()'; |
|
421 | + $label = $methodName.'()'; |
|
422 | 422 | $docsPreamble = ''; |
423 | 423 | // Figure out the type |
424 | 424 | if ($docblock) { |
@@ -426,7 +426,7 @@ discard block |
||
426 | 426 | if ($tags) { |
427 | 427 | $docsPreamble = "Parameters:\n\n"; |
428 | 428 | foreach ($tags as $tag) { |
429 | - $docsPreamble .= $tag . "\n"; |
|
429 | + $docsPreamble .= $tag."\n"; |
|
430 | 430 | } |
431 | 431 | $docsPreamble .= "\n"; |
432 | 432 | } |
@@ -434,11 +434,11 @@ discard block |
||
434 | 434 | ArrayHelper::setValue($completionList, $thisPath, [ |
435 | 435 | self::COMPLETION_KEY => [ |
436 | 436 | 'detail' => $detail, |
437 | - 'documentation' => $docsPreamble . $docs, |
|
437 | + 'documentation' => $docsPreamble.$docs, |
|
438 | 438 | 'kind' => self::CompletionItemKind['Method'], |
439 | 439 | 'label' => $label, |
440 | 440 | 'insertText' => $label, |
441 | - 'sortText' => '~~~' . $label, |
|
441 | + 'sortText' => '~~~'.$label, |
|
442 | 442 | ] |
443 | 443 | ]); |
444 | 444 | } |
@@ -81,24 +81,24 @@ |
||
81 | 81 | $metaContainers = Seomatic::$plugin->metaContainers; |
82 | 82 | // Get our cache key |
83 | 83 | $asArrayKey = $asArray ? 'true' : 'false'; |
84 | - $cacheKey = $uri . $siteId . implode($containerKeys) . $asArrayKey . Seomatic::$environment; |
|
84 | + $cacheKey = $uri.$siteId.implode($containerKeys).$asArrayKey.Seomatic::$environment; |
|
85 | 85 | // Load the meta containers |
86 | 86 | $dependency = new TagDependency([ |
87 | 87 | 'tags' => [ |
88 | 88 | $metaContainers::GLOBAL_METACONTAINER_CACHE_TAG, |
89 | - $metaContainers::METACONTAINER_CACHE_TAG . $sourceId . $sourceBundleType . $siteId, |
|
90 | - $metaContainers::METACONTAINER_CACHE_TAG . $uri . $siteId, |
|
91 | - $metaContainers::METACONTAINER_CACHE_TAG . $cacheKey, |
|
89 | + $metaContainers::METACONTAINER_CACHE_TAG.$sourceId.$sourceBundleType.$siteId, |
|
90 | + $metaContainers::METACONTAINER_CACHE_TAG.$uri.$siteId, |
|
91 | + $metaContainers::METACONTAINER_CACHE_TAG.$cacheKey, |
|
92 | 92 | ], |
93 | 93 | ]); |
94 | 94 | |
95 | 95 | $cache = Craft::$app->getCache(); |
96 | 96 | $result = $cache->getOrSet( |
97 | - self::CACHE_KEY . $cacheKey, |
|
98 | - function () use ($uri, $siteId, $containerKeys, $asArray) { |
|
97 | + self::CACHE_KEY.$cacheKey, |
|
98 | + function() use ($uri, $siteId, $containerKeys, $asArray) { |
|
99 | 99 | $result = []; |
100 | 100 | Craft::info( |
101 | - 'Meta controller container cache miss: ' . $uri . '/' . $siteId, |
|
101 | + 'Meta controller container cache miss: '.$uri.'/'.$siteId, |
|
102 | 102 | __METHOD__ |
103 | 103 | ); |
104 | 104 | // Load the meta containers and parse our globals |
@@ -294,7 +294,7 @@ discard block |
||
294 | 294 | $metaValue = Craft::t( |
295 | 295 | 'seomatic', |
296 | 296 | 'Error rendering `{template}` -> {error}', |
297 | - ['template' => $metaValue, 'error' => $e->getMessage() . ' - ' . print_r($metaValue, true)] |
|
297 | + ['template' => $metaValue, 'error' => $e->getMessage().' - '.print_r($metaValue, true)] |
|
298 | 298 | ); |
299 | 299 | Craft::error($metaValue, __METHOD__); |
300 | 300 | Craft::$app->getErrorHandler()->logException($e); |
@@ -313,7 +313,7 @@ discard block |
||
313 | 313 | // Handle being passed in an object |
314 | 314 | if (is_object($metaValue)) { |
315 | 315 | if ($metaValue instanceof Markup) { |
316 | - return trim(html_entity_decode((string)$metaValue, ENT_NOQUOTES, 'UTF-8')); |
|
316 | + return trim(html_entity_decode((string) $metaValue, ENT_NOQUOTES, 'UTF-8')); |
|
317 | 317 | } |
318 | 318 | if ($metaValue instanceof Asset) { |
319 | 319 | /** @var Asset $metaValue */ |