Passed
Push — develop-v3 ( adcba5...bfec1a )
by Andrew
13:14 queued 07:27
created
src/ga4/Analytics.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -352,7 +352,7 @@
 block discarded – undo
352 352
             // Load them up for GA4
353 353
             foreach ($campaignParams as $key => $method) {
354 354
                 $value = $request->getParam($key) ?? $session->get($key) ?? null;
355
-                $method = 'set' . $method;
355
+                $method = 'set'.$method;
356 356
 
357 357
                 $this->$method($value);
358 358
 
Please login to merge, or discard this patch.
src/services/ServicesTrait.php 1 patch
Spacing   +4 added lines, -4 removed lines patch added patch discarded remove patch
@@ -33,8 +33,8 @@  discard block
 block discarded – undo
33 33
         // so we can't extract it from the passed in $config
34 34
         $majorVersion = '3';
35 35
         // Dev server container name & port are based on the major version of this plugin
36
-        $devPort = 3000 + (int)$majorVersion;
37
-        $versionName = 'v' . $majorVersion;
36
+        $devPort = 3000 + (int) $majorVersion;
37
+        $versionName = 'v'.$majorVersion;
38 38
         // Merge in the passed config, so it our config can be overridden by Plugins::pluginConfigs['vite']
39 39
         // ref: https://github.com/craftcms/cms/issues/1989
40 40
         $config = ArrayHelper::merge([
@@ -46,8 +46,8 @@  discard block
 block discarded – undo
46 46
                     'assetClass' => InstantAnalyticsAsset::class,
47 47
                     'checkDevServer' => true,
48 48
                     'class' => VitePluginService::class,
49
-                    'devServerInternal' => 'http://craft-instantanalytics-ga4-' . $versionName . '-buildchain-dev:' . $devPort,
50
-                    'devServerPublic' => 'http://localhost:' . $devPort,
49
+                    'devServerInternal' => 'http://craft-instantanalytics-ga4-'.$versionName.'-buildchain-dev:'.$devPort,
50
+                    'devServerPublic' => 'http://localhost:'.$devPort,
51 51
                     'errorEntry' => 'src/js/app.ts',
52 52
                     'useDevServer' => true,
53 53
                 ],
Please login to merge, or discard this patch.
src/InstantAnalytics.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -380,7 +380,7 @@
 block discarded – undo
380 380
             });
381 381
 
382 382
             // Check to make sure Order::EVENT_AFTER_REMOVE_LINE_ITEM is defined
383
-            if (defined(Order::class . '::EVENT_AFTER_REMOVE_LINE_ITEM')) {
383
+            if (defined(Order::class.'::EVENT_AFTER_REMOVE_LINE_ITEM')) {
384 384
                 Event::on(Order::class, Order::EVENT_AFTER_REMOVE_LINE_ITEM, function(LineItemEvent $e): void {
385 385
                     $lineItem = $e->lineItem;
386 386
                     if (self::$settings->autoSendRemoveFromCart) {
Please login to merge, or discard this patch.
src/services/Commerce.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -313,7 +313,7 @@  discard block
 block discarded – undo
313 313
 
314 314
         $eventItem->setItemId($variant->sku);
315 315
         $eventItem->setItemName($variant->title);
316
-        $eventItem->setPrice((float)number_format($variant->price, 2, '.', ''));
316
+        $eventItem->setPrice((float) number_format($variant->price, 2, '.', ''));
317 317
 
318 318
         $category = ($isVariant ? $variant->getProduct() : $productVariant)->getType()['name'];
319 319
 
@@ -430,7 +430,7 @@  discard block
 block discarded – undo
430 430
                 $name = $cat->title;
431 431
 
432 432
                 while ($cat = $cat->parent) {
433
-                    $name = $cat->title . '/' . $name;
433
+                    $name = $cat->title.'/'.$name;
434 434
                 }
435 435
 
436 436
                 $cats[] = $name;
Please login to merge, or discard this patch.
src/helpers/Analytics.php 1 patch
Spacing   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -71,7 +71,7 @@  discard block
 block discarded – undo
71 71
             $urlParts = parse_url($url);
72 72
             $url = $urlParts['path'] ?? '/';
73 73
             if (isset($urlParts['query'])) {
74
-                $url .= '?' . $urlParts['query'];
74
+                $url .= '?'.$urlParts['query'];
75 75
             }
76 76
         }
77 77
 
@@ -112,7 +112,7 @@  discard block
 block discarded – undo
112 112
         $path = parse_url($url, PHP_URL_PATH);
113 113
         $pathFragments = explode('/', rtrim($path, '/'));
114 114
         $fileName = end($pathFragments);
115
-        $trackingUrl = UrlHelper::siteUrl('instantanalytics/pageViewTrack/' . $fileName, $urlParams);
115
+        $trackingUrl = UrlHelper::siteUrl('instantanalytics/pageViewTrack/'.$fileName, $urlParams);
116 116
 
117 117
         InstantAnalytics::$plugin->logAnalyticsEvent(
118 118
             'Created pageViewTrackingUrl for: {trackingUrl}',
@@ -142,7 +142,7 @@  discard block
 block discarded – undo
142 142
         $urlParams = compact('url', 'eventName', 'params');
143 143
 
144 144
         $fileName = pathinfo(parse_url($url, PHP_URL_PATH), PATHINFO_BASENAME);
145
-        $trackingUrl = UrlHelper::siteUrl('instantanalytics/eventTrack/' . $fileName, $urlParams);
145
+        $trackingUrl = UrlHelper::siteUrl('instantanalytics/eventTrack/'.$fileName, $urlParams);
146 146
 
147 147
         InstantAnalytics::$plugin->logAnalyticsEvent(
148 148
             'Created eventTrackingUrl for: {trackingUrl}',
@@ -274,7 +274,7 @@  discard block
 block discarded – undo
274 274
             $cid = $_COOKIE['_ia'];
275 275
         } else {
276 276
             // Generate our own client id, otherwise.
277
-            $cid = static::gaGenUUID() . '.1';
277
+            $cid = static::gaGenUUID().'.1';
278 278
         }
279 279
 
280 280
         if (InstantAnalytics::$settings->createGclidCookie && !empty($cid)) {
@@ -293,7 +293,7 @@  discard block
 block discarded – undo
293 293
     {
294 294
         $sessionString = '';
295 295
         $measurementId = Craft::parseEnv(InstantAnalytics::$settings->googleAnalyticsMeasurementId);
296
-        $cookieName = '_ga_' . StringHelper::removeLeft($measurementId, 'G-');
296
+        $cookieName = '_ga_'.StringHelper::removeLeft($measurementId, 'G-');
297 297
 
298 298
         if (isset($_COOKIE[$cookieName])) {
299 299
             $parts = explode(".", $_COOKIE[$cookieName], 5);
Please login to merge, or discard this patch.
src/helpers/Field.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -191,7 +191,7 @@
 block discarded – undo
191 191
                 $prefix = $global->handle;
192 192
                 $fields = array_combine(
193 193
                     array_map(function($key) use ($prefix) {
194
-                        return $prefix . '.' . $key;
194
+                        return $prefix.'.'.$key;
195 195
                     }, array_keys($fields)),
196 196
                     $fields
197 197
                 );
Please login to merge, or discard this patch.
src/ga4/ComponentFactory.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -82,7 +82,7 @@
 block discarded – undo
82 82
         ];
83 83
 
84 84
         if (!array_key_exists($componentName, $componentMap)) {
85
-            throw new InvalidArgumentException(Craft::t('instant-analytics-ga4', 'Unknown event type - ' . $componentName));
85
+            throw new InvalidArgumentException(Craft::t('instant-analytics-ga4', 'Unknown event type - '.$componentName));
86 86
         }
87 87
         
88 88
         return new $componentMap[$componentName]();
Please login to merge, or discard this patch.
ecs.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -5,7 +5,7 @@
 block discarded – undo
5 5
 
6 6
 return static function(ECSConfig $ecsConfig): void {
7 7
     $ecsConfig->paths([
8
-        __DIR__ . '/src',
8
+        __DIR__.'/src',
9 9
         __FILE__,
10 10
     ]);
11 11
     $ecsConfig->parallel();
Please login to merge, or discard this patch.