Passed
Push — v3 ( 9af8ac...482808 )
by Andrew
20:05 queued 13s
created
src/models/MetaJsonLd.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -114,7 +114,7 @@  discard block
 block discarded – undo
114 114
     {
115 115
         $model = null;
116 116
 
117
-        $className = 'nystudio107\\seomatic\\models\\jsonld\\' . $schemaType;
117
+        $className = 'nystudio107\\seomatic\\models\\jsonld\\'.$schemaType;
118 118
         /** @var $model MetaJsonLd */
119 119
         if (class_exists($className)) {
120 120
             self::cleanProperties($className, $config);
@@ -371,7 +371,7 @@  discard block
 block discarded – undo
371 371
             foreach ($dataToValidate as $key => $data) {
372 372
                 /** @var array $expectedTypes */
373 373
                 foreach ($expectedTypes as $expectedType) {
374
-                    $className = 'nystudio107\\seomatic\\models\\jsonld\\' . $expectedType;
374
+                    $className = 'nystudio107\\seomatic\\models\\jsonld\\'.$expectedType;
375 375
                     switch ($expectedType) {
376 376
                         // Text always validates
377 377
                         case 'Text':
@@ -411,7 +411,7 @@  discard block
 block discarded – undo
411 411
                         case 'Date':
412 412
                             $validator = new DateValidator();
413 413
                             $validator->type = DateValidator::TYPE_DATE;
414
-                            $validator->format = 'php:' . DateTime::ATOM;
414
+                            $validator->format = 'php:'.DateTime::ATOM;
415 415
                             if ($validator->validate($data, $error)) {
416 416
                                 $validated = true;
417 417
                             }
@@ -457,7 +457,7 @@  discard block
 block discarded – undo
457 457
                                 $validated = true;
458 458
                             }
459 459
                             if (is_string($data)) {
460
-                                $targetClass = 'nystudio107\\seomatic\\models\\jsonld\\' . $data;
460
+                                $targetClass = 'nystudio107\\seomatic\\models\\jsonld\\'.$data;
461 461
                                 if (class_exists($targetClass)) {
462 462
                                     $validated = true;
463 463
                                 }
@@ -466,7 +466,7 @@  discard block
 block discarded – undo
466 466
                     }
467 467
                 }
468 468
                 if (!$validated) {
469
-                    $this->addError($attribute, 'Must be one of these types: ' . implode(', ', $expectedTypes));
469
+                    $this->addError($attribute, 'Must be one of these types: '.implode(', ', $expectedTypes));
470 470
                 }
471 471
             }
472 472
         }
Please login to merge, or discard this patch.
src/models/MetaTitle.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -148,10 +148,10 @@  discard block
 block discarded – undo
148 148
                     break;
149 149
             }
150 150
             // Handle the case of empty titles
151
-            if ($prefix === (' ' . $separator . ' ')) {
151
+            if ($prefix === (' '.$separator.' ')) {
152 152
                 $prefix = '';
153 153
             }
154
-            if ($suffix === (' ' . $separator)) {
154
+            if ($suffix === (' '.$separator)) {
155 155
                 $suffix = '';
156 156
             }
157 157
             // Remove potential double spaces
@@ -159,7 +159,7 @@  discard block
 block discarded – undo
159 159
             ;
160 160
             $suffix = preg_replace('/\s+/', ' ', $suffix);
161 161
             ;
162
-            $lengthAdjust = mb_strlen($prefix . $suffix);
162
+            $lengthAdjust = mb_strlen($prefix.$suffix);
163 163
             // Parse the data
164 164
             $scenario = $this->scenario;
165 165
             $this->setScenario('render');
@@ -178,7 +178,7 @@  discard block
 block discarded – undo
178 178
                         '…'
179 179
                     );
180 180
                 }
181
-                $data = $prefix . $data . $suffix;
181
+                $data = $prefix.$data.$suffix;
182 182
             } else {
183 183
                 // If no title is provided, just use the site name
184 184
                 $data = MetaValueHelper::parseString($this->siteName);
@@ -187,7 +187,7 @@  discard block
 block discarded – undo
187 187
             $data = trim($data);
188 188
             // devMode
189 189
             if (Seomatic::$devMode) {
190
-                $data = Seomatic::$settings->devModeTitlePrefix . $data;
190
+                $data = Seomatic::$settings->devModeTitlePrefix.$data;
191 191
             }
192 192
         }
193 193
 
Please login to merge, or discard this patch.
src/models/MetaTitleContainer.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -48,16 +48,16 @@
 block discarded – undo
48 48
     public function includeMetaData($dependency)
49 49
     {
50 50
         Craft::beginProfile('MetaTitleContainer::includeMetaData', __METHOD__);
51
-        $uniqueKey = $this->handle . $dependency->tags[3];
51
+        $uniqueKey = $this->handle.$dependency->tags[3];
52 52
         $cache = Craft::$app->getCache();
53 53
         if ($this->clearCache) {
54 54
             TagDependency::invalidate($cache, $dependency->tags[3]);
55 55
         }
56 56
         $tagData = $cache->getOrSet(
57
-            self::CONTAINER_TYPE . $uniqueKey,
57
+            self::CONTAINER_TYPE.$uniqueKey,
58 58
             function() use ($uniqueKey) {
59 59
                 Craft::info(
60
-                    self::CONTAINER_TYPE . ' cache miss: ' . $uniqueKey,
60
+                    self::CONTAINER_TYPE.' cache miss: '.$uniqueKey,
61 61
                     __METHOD__
62 62
                 );
63 63
                 $tagData = '';
Please login to merge, or discard this patch.
src/models/MetaScriptContainer.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -55,16 +55,16 @@  discard block
 block discarded – undo
55 55
     public function includeMetaData($dependency)
56 56
     {
57 57
         Craft::beginProfile('MetaScriptContainer::includeMetaData', __METHOD__);
58
-        $uniqueKey = $this->handle . $dependency->tags[3] . $this->dataLayerHash();
58
+        $uniqueKey = $this->handle.$dependency->tags[3].$this->dataLayerHash();
59 59
         $cache = Craft::$app->getCache();
60 60
         if ($this->clearCache) {
61 61
             TagDependency::invalidate($cache, $dependency->tags[3]);
62 62
         }
63 63
         $tagData = $cache->getOrSet(
64
-            self::CONTAINER_TYPE . $uniqueKey,
64
+            self::CONTAINER_TYPE.$uniqueKey,
65 65
             function() use ($uniqueKey) {
66 66
                 Craft::info(
67
-                    self::CONTAINER_TYPE . ' cache miss: ' . $uniqueKey,
67
+                    self::CONTAINER_TYPE.' cache miss: '.$uniqueKey,
68 68
                     __METHOD__
69 69
                 );
70 70
                 
@@ -140,7 +140,7 @@  discard block
 block discarded – undo
140 140
                     'jQuery(window).load()',
141 141
                 ];
142 142
                 $position = $positionNames[$config['position'] - 1] ?? 'unknown';
143
-                $html .= "<!-- Position: {$position} -->" . PHP_EOL;
143
+                $html .= "<!-- Position: {$position} -->".PHP_EOL;
144 144
             }
145 145
             if ($bodyJs || !$params['renderScriptTags']) {
146 146
                 $html .= $config['js'];
Please login to merge, or discard this patch.
src/models/MetaLinkContainer.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -49,16 +49,16 @@
 block discarded – undo
49 49
     public function includeMetaData($dependency)
50 50
     {
51 51
         Craft::beginProfile('MetaLinkContainer::includeMetaData', __METHOD__);
52
-        $uniqueKey = $this->handle . $dependency->tags[3];
52
+        $uniqueKey = $this->handle.$dependency->tags[3];
53 53
         $cache = Craft::$app->getCache();
54 54
         if ($this->clearCache) {
55 55
             TagDependency::invalidate($cache, $dependency->tags[3]);
56 56
         }
57 57
         $tagData = $cache->getOrSet(
58
-            self::CONTAINER_TYPE . $uniqueKey,
58
+            self::CONTAINER_TYPE.$uniqueKey,
59 59
             function() use ($uniqueKey) {
60 60
                 Craft::info(
61
-                    self::CONTAINER_TYPE . ' cache miss: ' . $uniqueKey,
61
+                    self::CONTAINER_TYPE.' cache miss: '.$uniqueKey,
62 62
                     __METHOD__
63 63
                 );
64 64
                 $tagData = [];
Please login to merge, or discard this patch.
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.