Passed
Push — v3 ( 8a04fd...e916ab )
by Andrew
20:43 queued 14s
created
src/seomatic-config/campaignmeta/TagContainer.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,44 +19,44 @@
 block discarded – undo
19 19
  */
20 20
 
21 21
 return [
22
-    MetaTagContainer::CONTAINER_TYPE . TagService::GENERAL_HANDLE => [
22
+    MetaTagContainer::CONTAINER_TYPE.TagService::GENERAL_HANDLE => [
23 23
         'name' => 'General',
24 24
         'description' => 'General Meta Tags',
25 25
         'handle' => TagService::GENERAL_HANDLE,
26
-        'class' => (string)MetaTagContainer::class,
26
+        'class' => (string) MetaTagContainer::class,
27 27
         'include' => true,
28 28
         'dependencies' => [
29 29
         ],
30 30
         'data' => [
31 31
         ],
32 32
     ],
33
-    MetaTagContainer::CONTAINER_TYPE . TagService::FACEBOOK_HANDLE => [
33
+    MetaTagContainer::CONTAINER_TYPE.TagService::FACEBOOK_HANDLE => [
34 34
         'name' => 'Facebook',
35 35
         'description' => 'Facebook OpenGraph Meta Tags',
36 36
         'handle' => TagService::FACEBOOK_HANDLE,
37
-        'class' => (string)MetaTagContainer::class,
37
+        'class' => (string) MetaTagContainer::class,
38 38
         'include' => true,
39 39
         'dependencies' => [
40 40
         ],
41 41
         'data' => [
42 42
         ],
43 43
     ],
44
-    MetaTagContainer::CONTAINER_TYPE . TagService::TWITTER_HANDLE => [
44
+    MetaTagContainer::CONTAINER_TYPE.TagService::TWITTER_HANDLE => [
45 45
         'name' => 'Twitter',
46 46
         'description' => 'Twitter Card Meta Tags',
47 47
         'handle' => TagService::TWITTER_HANDLE,
48
-        'class' => (string)MetaTagContainer::class,
48
+        'class' => (string) MetaTagContainer::class,
49 49
         'include' => true,
50 50
         'dependencies' => [
51 51
         ],
52 52
         'data' => [
53 53
         ],
54 54
     ],
55
-    MetaTagContainer::CONTAINER_TYPE . TagService::MISC_HANDLE => [
55
+    MetaTagContainer::CONTAINER_TYPE.TagService::MISC_HANDLE => [
56 56
         'name' => 'Miscellaneous',
57 57
         'description' => 'Miscellaneous Meta Tags',
58 58
         'handle' => TagService::MISC_HANDLE,
59
-        'class' => (string)MetaTagContainer::class,
59
+        'class' => (string) MetaTagContainer::class,
60 60
         'include' => true,
61 61
         'dependencies' => [
62 62
         ],
Please login to merge, or discard this patch.
src/seomatic-config/fieldmeta/TagContainer.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,44 +19,44 @@
 block discarded – undo
19 19
  */
20 20
 
21 21
 return [
22
-    MetaTagContainer::CONTAINER_TYPE . TagService::GENERAL_HANDLE => [
22
+    MetaTagContainer::CONTAINER_TYPE.TagService::GENERAL_HANDLE => [
23 23
         'name' => 'General',
24 24
         'description' => 'General Meta Tags',
25 25
         'handle' => TagService::GENERAL_HANDLE,
26
-        'class' => (string)MetaTagContainer::class,
26
+        'class' => (string) MetaTagContainer::class,
27 27
         'include' => true,
28 28
         'dependencies' => [
29 29
         ],
30 30
         'data' => [
31 31
         ],
32 32
     ],
33
-    MetaTagContainer::CONTAINER_TYPE . TagService::FACEBOOK_HANDLE => [
33
+    MetaTagContainer::CONTAINER_TYPE.TagService::FACEBOOK_HANDLE => [
34 34
         'name' => 'Facebook',
35 35
         'description' => 'Facebook OpenGraph Meta Tags',
36 36
         'handle' => TagService::FACEBOOK_HANDLE,
37
-        'class' => (string)MetaTagContainer::class,
37
+        'class' => (string) MetaTagContainer::class,
38 38
         'include' => true,
39 39
         'dependencies' => [
40 40
         ],
41 41
         'data' => [
42 42
         ],
43 43
     ],
44
-    MetaTagContainer::CONTAINER_TYPE . TagService::TWITTER_HANDLE => [
44
+    MetaTagContainer::CONTAINER_TYPE.TagService::TWITTER_HANDLE => [
45 45
         'name' => 'Twitter',
46 46
         'description' => 'Twitter Card Meta Tags',
47 47
         'handle' => TagService::TWITTER_HANDLE,
48
-        'class' => (string)MetaTagContainer::class,
48
+        'class' => (string) MetaTagContainer::class,
49 49
         'include' => true,
50 50
         'dependencies' => [
51 51
         ],
52 52
         'data' => [
53 53
         ],
54 54
     ],
55
-    MetaTagContainer::CONTAINER_TYPE . TagService::MISC_HANDLE => [
55
+    MetaTagContainer::CONTAINER_TYPE.TagService::MISC_HANDLE => [
56 56
         'name' => 'Miscellaneous',
57 57
         'description' => 'Miscellaneous Meta Tags',
58 58
         'handle' => TagService::MISC_HANDLE,
59
-        'class' => (string)MetaTagContainer::class,
59
+        'class' => (string) MetaTagContainer::class,
60 60
         'include' => true,
61 61
         'dependencies' => [
62 62
         ],
Please login to merge, or discard this patch.
src/seomatic-config/productmeta/TagContainer.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,44 +19,44 @@
 block discarded – undo
19 19
  */
20 20
 
21 21
 return [
22
-    MetaTagContainer::CONTAINER_TYPE . TagService::GENERAL_HANDLE => [
22
+    MetaTagContainer::CONTAINER_TYPE.TagService::GENERAL_HANDLE => [
23 23
         'name' => 'General',
24 24
         'description' => 'General Meta Tags',
25 25
         'handle' => TagService::GENERAL_HANDLE,
26
-        'class' => (string)MetaTagContainer::class,
26
+        'class' => (string) MetaTagContainer::class,
27 27
         'include' => true,
28 28
         'dependencies' => [
29 29
         ],
30 30
         'data' => [
31 31
         ],
32 32
     ],
33
-    MetaTagContainer::CONTAINER_TYPE . TagService::FACEBOOK_HANDLE => [
33
+    MetaTagContainer::CONTAINER_TYPE.TagService::FACEBOOK_HANDLE => [
34 34
         'name' => 'Facebook',
35 35
         'description' => 'Facebook OpenGraph Meta Tags',
36 36
         'handle' => TagService::FACEBOOK_HANDLE,
37
-        'class' => (string)MetaTagContainer::class,
37
+        'class' => (string) MetaTagContainer::class,
38 38
         'include' => true,
39 39
         'dependencies' => [
40 40
         ],
41 41
         'data' => [
42 42
         ],
43 43
     ],
44
-    MetaTagContainer::CONTAINER_TYPE . TagService::TWITTER_HANDLE => [
44
+    MetaTagContainer::CONTAINER_TYPE.TagService::TWITTER_HANDLE => [
45 45
         'name' => 'Twitter',
46 46
         'description' => 'Twitter Card Meta Tags',
47 47
         'handle' => TagService::TWITTER_HANDLE,
48
-        'class' => (string)MetaTagContainer::class,
48
+        'class' => (string) MetaTagContainer::class,
49 49
         'include' => true,
50 50
         'dependencies' => [
51 51
         ],
52 52
         'data' => [
53 53
         ],
54 54
     ],
55
-    MetaTagContainer::CONTAINER_TYPE . TagService::MISC_HANDLE => [
55
+    MetaTagContainer::CONTAINER_TYPE.TagService::MISC_HANDLE => [
56 56
         'name' => 'Miscellaneous',
57 57
         'description' => 'Miscellaneous Meta Tags',
58 58
         'handle' => TagService::MISC_HANDLE,
59
-        'class' => (string)MetaTagContainer::class,
59
+        'class' => (string) MetaTagContainer::class,
60 60
         'include' => true,
61 61
         'dependencies' => [
62 62
         ],
Please login to merge, or discard this patch.
src/seomatic-config/eventmeta/TagContainer.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,44 +19,44 @@
 block discarded – undo
19 19
  */
20 20
 
21 21
 return [
22
-    MetaTagContainer::CONTAINER_TYPE . TagService::GENERAL_HANDLE => [
22
+    MetaTagContainer::CONTAINER_TYPE.TagService::GENERAL_HANDLE => [
23 23
         'name' => 'General',
24 24
         'description' => 'General Meta Tags',
25 25
         'handle' => TagService::GENERAL_HANDLE,
26
-        'class' => (string)MetaTagContainer::class,
26
+        'class' => (string) MetaTagContainer::class,
27 27
         'include' => true,
28 28
         'dependencies' => [
29 29
         ],
30 30
         'data' => [
31 31
         ],
32 32
     ],
33
-    MetaTagContainer::CONTAINER_TYPE . TagService::FACEBOOK_HANDLE => [
33
+    MetaTagContainer::CONTAINER_TYPE.TagService::FACEBOOK_HANDLE => [
34 34
         'name' => 'Facebook',
35 35
         'description' => 'Facebook OpenGraph Meta Tags',
36 36
         'handle' => TagService::FACEBOOK_HANDLE,
37
-        'class' => (string)MetaTagContainer::class,
37
+        'class' => (string) MetaTagContainer::class,
38 38
         'include' => true,
39 39
         'dependencies' => [
40 40
         ],
41 41
         'data' => [
42 42
         ],
43 43
     ],
44
-    MetaTagContainer::CONTAINER_TYPE . TagService::TWITTER_HANDLE => [
44
+    MetaTagContainer::CONTAINER_TYPE.TagService::TWITTER_HANDLE => [
45 45
         'name' => 'Twitter',
46 46
         'description' => 'Twitter Card Meta Tags',
47 47
         'handle' => TagService::TWITTER_HANDLE,
48
-        'class' => (string)MetaTagContainer::class,
48
+        'class' => (string) MetaTagContainer::class,
49 49
         'include' => true,
50 50
         'dependencies' => [
51 51
         ],
52 52
         'data' => [
53 53
         ],
54 54
     ],
55
-    MetaTagContainer::CONTAINER_TYPE . TagService::MISC_HANDLE => [
55
+    MetaTagContainer::CONTAINER_TYPE.TagService::MISC_HANDLE => [
56 56
         'name' => 'Miscellaneous',
57 57
         'description' => 'Miscellaneous Meta Tags',
58 58
         'handle' => TagService::MISC_HANDLE,
59
-        'class' => (string)MetaTagContainer::class,
59
+        'class' => (string) MetaTagContainer::class,
60 60
         'include' => true,
61 61
         'dependencies' => [
62 62
         ],
Please login to merge, or discard this patch.
src/seomatic-config/entrymeta/TagContainer.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,44 +19,44 @@
 block discarded – undo
19 19
  */
20 20
 
21 21
 return [
22
-    MetaTagContainer::CONTAINER_TYPE . TagService::GENERAL_HANDLE => [
22
+    MetaTagContainer::CONTAINER_TYPE.TagService::GENERAL_HANDLE => [
23 23
         'name' => 'General',
24 24
         'description' => 'General Meta Tags',
25 25
         'handle' => TagService::GENERAL_HANDLE,
26
-        'class' => (string)MetaTagContainer::class,
26
+        'class' => (string) MetaTagContainer::class,
27 27
         'include' => true,
28 28
         'dependencies' => [
29 29
         ],
30 30
         'data' => [
31 31
         ],
32 32
     ],
33
-    MetaTagContainer::CONTAINER_TYPE . TagService::FACEBOOK_HANDLE => [
33
+    MetaTagContainer::CONTAINER_TYPE.TagService::FACEBOOK_HANDLE => [
34 34
         'name' => 'Facebook',
35 35
         'description' => 'Facebook OpenGraph Meta Tags',
36 36
         'handle' => TagService::FACEBOOK_HANDLE,
37
-        'class' => (string)MetaTagContainer::class,
37
+        'class' => (string) MetaTagContainer::class,
38 38
         'include' => true,
39 39
         'dependencies' => [
40 40
         ],
41 41
         'data' => [
42 42
         ],
43 43
     ],
44
-    MetaTagContainer::CONTAINER_TYPE . TagService::TWITTER_HANDLE => [
44
+    MetaTagContainer::CONTAINER_TYPE.TagService::TWITTER_HANDLE => [
45 45
         'name' => 'Twitter',
46 46
         'description' => 'Twitter Card Meta Tags',
47 47
         'handle' => TagService::TWITTER_HANDLE,
48
-        'class' => (string)MetaTagContainer::class,
48
+        'class' => (string) MetaTagContainer::class,
49 49
         'include' => true,
50 50
         'dependencies' => [
51 51
         ],
52 52
         'data' => [
53 53
         ],
54 54
     ],
55
-    MetaTagContainer::CONTAINER_TYPE . TagService::MISC_HANDLE => [
55
+    MetaTagContainer::CONTAINER_TYPE.TagService::MISC_HANDLE => [
56 56
         'name' => 'Miscellaneous',
57 57
         'description' => 'Miscellaneous Meta Tags',
58 58
         'handle' => TagService::MISC_HANDLE,
59
-        'class' => (string)MetaTagContainer::class,
59
+        'class' => (string) MetaTagContainer::class,
60 60
         'include' => true,
61 61
         'dependencies' => [
62 62
         ],
Please login to merge, or discard this patch.
src/seomatic-config/digitalproductmeta/TagContainer.php 1 patch
Spacing   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -19,44 +19,44 @@
 block discarded – undo
19 19
  */
20 20
 
21 21
 return [
22
-    MetaTagContainer::CONTAINER_TYPE . TagService::GENERAL_HANDLE => [
22
+    MetaTagContainer::CONTAINER_TYPE.TagService::GENERAL_HANDLE => [
23 23
         'name' => 'General',
24 24
         'description' => 'General Meta Tags',
25 25
         'handle' => TagService::GENERAL_HANDLE,
26
-        'class' => (string)MetaTagContainer::class,
26
+        'class' => (string) MetaTagContainer::class,
27 27
         'include' => true,
28 28
         'dependencies' => [
29 29
         ],
30 30
         'data' => [
31 31
         ],
32 32
     ],
33
-    MetaTagContainer::CONTAINER_TYPE . TagService::FACEBOOK_HANDLE => [
33
+    MetaTagContainer::CONTAINER_TYPE.TagService::FACEBOOK_HANDLE => [
34 34
         'name' => 'Facebook',
35 35
         'description' => 'Facebook OpenGraph Meta Tags',
36 36
         'handle' => TagService::FACEBOOK_HANDLE,
37
-        'class' => (string)MetaTagContainer::class,
37
+        'class' => (string) MetaTagContainer::class,
38 38
         'include' => true,
39 39
         'dependencies' => [
40 40
         ],
41 41
         'data' => [
42 42
         ],
43 43
     ],
44
-    MetaTagContainer::CONTAINER_TYPE . TagService::TWITTER_HANDLE => [
44
+    MetaTagContainer::CONTAINER_TYPE.TagService::TWITTER_HANDLE => [
45 45
         'name' => 'Twitter',
46 46
         'description' => 'Twitter Card Meta Tags',
47 47
         'handle' => TagService::TWITTER_HANDLE,
48
-        'class' => (string)MetaTagContainer::class,
48
+        'class' => (string) MetaTagContainer::class,
49 49
         'include' => true,
50 50
         'dependencies' => [
51 51
         ],
52 52
         'data' => [
53 53
         ],
54 54
     ],
55
-    MetaTagContainer::CONTAINER_TYPE . TagService::MISC_HANDLE => [
55
+    MetaTagContainer::CONTAINER_TYPE.TagService::MISC_HANDLE => [
56 56
         'name' => 'Miscellaneous',
57 57
         'description' => 'Miscellaneous Meta Tags',
58 58
         'handle' => TagService::MISC_HANDLE,
59
-        'class' => (string)MetaTagContainer::class,
59
+        'class' => (string) MetaTagContainer::class,
60 60
         'include' => true,
61 61
         'dependencies' => [
62 62
         ],
Please login to merge, or discard this patch.
src/seoelements/SeoProduct.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -388,7 +388,7 @@
 block discarded – undo
388 388
             ConfigHelper::getConfigFromFile(self::configFilePath()),
389 389
             [
390 390
                 'sourceId' => $sourceModel->id,
391
-                'sourceName' => (string)$sourceModel->name,
391
+                'sourceName' => (string) $sourceModel->name,
392 392
                 'sourceHandle' => $sourceModel->handle,
393 393
             ]
394 394
         );
Please login to merge, or discard this patch.
src/seoelements/SeoCampaign.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -388,7 +388,7 @@
 block discarded – undo
388 388
             ConfigHelper::getConfigFromFile(self::configFilePath()),
389 389
             [
390 390
                 'sourceId' => $sourceModel->id,
391
-                'sourceName' => (string)$sourceModel->name,
391
+                'sourceName' => (string) $sourceModel->name,
392 392
                 'sourceHandle' => $sourceModel->handle,
393 393
             ]
394 394
         );
Please login to merge, or discard this patch.
src/helpers/Schema.php 1 patch
Spacing   +16 added lines, -16 removed lines patch added patch discarded remove patch
@@ -99,7 +99,7 @@  discard block
 block discarded – undo
99 99
             // Go from most specific type to least specific type
100 100
             foreach (self::SCHEMA_TYPES as $schemaType) {
101 101
                 if (!empty($settings[$schemaType]) && ($settings[$schemaType] !== 'none')) {
102
-                    $result = $settings[$schemaType] . self::SCHEMA_PATH_DELIMITER . $result;
102
+                    $result = $settings[$schemaType].self::SCHEMA_PATH_DELIMITER.$result;
103 103
                 }
104 104
             }
105 105
         }
@@ -124,7 +124,7 @@  discard block
 block discarded – undo
124 124
         if (isset($result['schemaTypeDescription'])) {
125 125
             $description = $result['schemaTypeDescription'];
126 126
             $description = preg_replace("`\[\[([A-z]*)\]\]`", '[$1](https://schema.org/$1)', $description);
127
-            $description = Markdown::process((string)$description);
127
+            $description = Markdown::process((string) $description);
128 128
             $description = str_replace(['<p>', '</p>', '\n'], ['', '', ' '], $description);
129 129
             $result['schemaTypeDescription'] = $description;
130 130
         }
@@ -143,7 +143,7 @@  discard block
 block discarded – undo
143 143
     {
144 144
         $result = [];
145 145
         while ($schemaType) {
146
-            $className = 'nystudio107\\seomatic\\models\\jsonld\\' . $schemaType;
146
+            $className = 'nystudio107\\seomatic\\models\\jsonld\\'.$schemaType;
147 147
             if (class_exists($className)) {
148 148
                 $classRef = new ReflectionClass($className);
149 149
                 $staticProps = $classRef->getStaticProperties();
@@ -242,15 +242,15 @@  discard block
 block discarded – undo
242 242
         $dependency = new TagDependency([
243 243
             'tags' => [
244 244
                 self::GLOBAL_SCHEMA_CACHE_TAG,
245
-                self::SCHEMA_CACHE_TAG . 'schemaArray',
245
+                self::SCHEMA_CACHE_TAG.'schemaArray',
246 246
             ],
247 247
         ]);
248 248
         $cache = Craft::$app->getCache();
249 249
         $typesArray = $cache->getOrSet(
250
-            self::CACHE_KEY . 'schemaArray',
250
+            self::CACHE_KEY.'schemaArray',
251 251
             function() use ($path) {
252 252
                 Craft::info(
253
-                    'schemaArray cache miss: ' . $path,
253
+                    'schemaArray cache miss: '.$path,
254 254
                     __METHOD__
255 255
                 );
256 256
                 $filePath = Craft::getAlias('@nystudio107/seomatic/resources/schema/tree.jsonld');
@@ -315,12 +315,12 @@  discard block
 block discarded – undo
315 315
         $dependency = new TagDependency([
316 316
             'tags' => [
317 317
                 self::GLOBAL_SCHEMA_CACHE_TAG,
318
-                self::SCHEMA_CACHE_TAG . 'schemaTree',
318
+                self::SCHEMA_CACHE_TAG.'schemaTree',
319 319
             ],
320 320
         ]);
321 321
         $cache = Craft::$app->getCache();
322 322
         $typesArray = $cache->getOrSet(
323
-            self::CACHE_KEY . 'schemaTree',
323
+            self::CACHE_KEY.'schemaTree',
324 324
             function() {
325 325
                 Craft::info(
326 326
                     'schemaTree cache miss',
@@ -384,11 +384,11 @@  discard block
 block discarded – undo
384 384
         foreach ($typesArray as $key => $value) {
385 385
             $indent = html_entity_decode(str_repeat('&nbsp;', $indentLevel));
386 386
             if (is_array($value)) {
387
-                $result[$key] = $indent . $key;
387
+                $result[$key] = $indent.$key;
388 388
                 $value = self::flattenSchemaArray($value, $indentLevel + self::MENU_INDENT_STEP);
389 389
                 $result = array_merge($result, $value);
390 390
             } else {
391
-                $result[$key] = $indent . $value;
391
+                $result[$key] = $indent.$value;
392 392
             }
393 393
         }
394 394
 
@@ -482,7 +482,7 @@  discard block
 block discarded – undo
482 482
             $children = [];
483 483
             $name = $typesArray['name'];
484 484
             // Construct a path-based $id, excluding the top-level `Thing` schema
485
-            $id = $name === 'Thing' ? '' : $path . self::SCHEMA_PATH_DELIMITER . $name;
485
+            $id = $name === 'Thing' ? '' : $path.self::SCHEMA_PATH_DELIMITER.$name;
486 486
             $id = ltrim($id, self::SCHEMA_PATH_DELIMITER);
487 487
             // Make sure we have at most 3 specifiers in the schema path
488 488
             $parts = explode(self::SCHEMA_PATH_DELIMITER, $id);
@@ -509,12 +509,12 @@  discard block
 block discarded – undo
509 509
             $schemaPath = explode(self::SCHEMA_PATH_DELIMITER, $id);
510 510
             // Use only the specific (last) type for now, rather than the complete path of types
511 511
             $schemaPath = [end($schemaPath)];
512
-            if ((bool)array_intersect($schemaPath, array_keys($googleRichSnippetTypes))) {
513
-                $name .= ' (' . Craft::t('seomatic', 'Google rich result') . ')';
512
+            if ((bool) array_intersect($schemaPath, array_keys($googleRichSnippetTypes))) {
513
+                $name .= ' ('.Craft::t('seomatic', 'Google rich result').')';
514 514
             }
515 515
             // Mark it as pending, if applicable
516 516
             if (isset($typesArray['pending']) && $typesArray['pending']) {
517
-                $name .= ' (' . Craft::t('seomatic', 'pending') . ')';
517
+                $name .= ' ('.Craft::t('seomatic', 'pending').')';
518 518
             }
519 519
             $result['label'] = $name;
520 520
             $result['id'] = $id;
@@ -533,12 +533,12 @@  discard block
 block discarded – undo
533 533
         $dependency = new TagDependency([
534 534
             'tags' => [
535 535
                 self::GLOBAL_SCHEMA_CACHE_TAG,
536
-                self::SCHEMA_CACHE_TAG . 'googleRichSnippets',
536
+                self::SCHEMA_CACHE_TAG.'googleRichSnippets',
537 537
             ],
538 538
         ]);
539 539
         $cache = Craft::$app->getCache();
540 540
         return $cache->getOrSet(
541
-            self::CACHE_KEY . 'googleRichSnippets',
541
+            self::CACHE_KEY.'googleRichSnippets',
542 542
             function() {
543 543
                 Craft::info(
544 544
                     'googleRichSnippets cache miss',
Please login to merge, or discard this patch.