Passed
Branch v4 (12362e)
by Benjamin
07:43
created
src/services/Analytics.php 1 patch
Braces   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -288,13 +288,13 @@
 block discarded – undo
288 288
             list($version, $domainDepth, $cid1, $cid2) = preg_split('[\.]', $_COOKIE["_ga"], 4);
289 289
             $contents = array('version' => $version, 'domainDepth' => $domainDepth, 'cid' => $cid1 . '.' . $cid2);
290 290
             $cid = $contents['cid'];
291
-        }
292
-        else
291
+        } else
293 292
         {
294
-            if (isset($_COOKIE['_ia']) && $_COOKIE['_ia'] !='' )
295
-                $cid = $_COOKIE['_ia'];
296
-            else
297
-                $cid = $this->_gaGenUUID();
293
+            if (isset($_COOKIE['_ia']) && $_COOKIE['_ia'] !='' ) {
294
+                            $cid = $_COOKIE['_ia'];
295
+            } else {
296
+                            $cid = $this->_gaGenUUID();
297
+            }
298 298
         }
299 299
         setcookie('_ia', $cid, time()+60*60*24*730, "/"); // Two years
300 300
         return $cid;
Please login to merge, or discard this patch.
src/controllers/UtilsController.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -132,8 +132,7 @@
 block discarded – undo
132 132
 
133 133
                         $columns[$column['id']] = $this->populateColumnAttributes($column, $item);
134 134
                     }
135
-                }
136
-                else
135
+                } else
137 136
                 {
138 137
                     $column = [];
139 138
                     $column['id'] = $item->id;
Please login to merge, or discard this patch.
src/controllers/OauthController.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -54,8 +54,7 @@
 block discarded – undo
54 54
             Analytics::$plugin->cache->delete(['accountExplorerData']);
55 55
 
56 56
             Craft::$app->getSession()->setNotice(Craft::t('analytics', "Disconnected from Google Analytics."));
57
-        }
58
-        else
57
+        } else
59 58
         {
60 59
             Craft::$app->getSession()->setError(Craft::t('analytics', "Couldn’t disconnect from Google Analytics"));
61 60
         }
Please login to merge, or discard this patch.
src/models/ReportRequestCriteria.php 1 patch
Braces   +1 added lines, -2 removed lines patch added patch discarded remove patch
@@ -111,8 +111,7 @@
 block discarded – undo
111 111
         {
112 112
             $response['report'] = Analytics::$plugin->getApis()->getAnalyticsReporting()->getReport($this, $toArray);
113 113
             $response['success'] = true;
114
-        }
115
-        catch(\Exception $e)
114
+        } catch(\Exception $e)
116 115
         {
117 116
             $response['error'] = true;
118 117
             $response['errorMessage'] = $e->getMessage();
Please login to merge, or discard this patch.