Passed
Push — master ( 054ae2...bf35ce )
by Paul
04:22
created
plugin/Controllers/Controller.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -38,7 +38,8 @@
 block discarded – undo
38 38
         }
39 39
         try {
40 40
             return glsr($handlerClass)->handle($command);
41
-        } catch (Exception $e) {
41
+        }
42
+        catch (Exception $e) {
42 43
             status_header(400);
43 44
             glsr(Notice::class)->addError(new WP_Error('site_reviews_error', $e->getMessage()));
44 45
             glsr_log()->error($e->getMessage());
Please login to merge, or discard this patch.
plugin/Database.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -116,7 +116,8 @@
 block discarded – undo
116 116
         ];
117 117
         if (is_numeric($searchTerm)) {
118 118
             $args['post__in'] = [$searchTerm];
119
-        } else {
119
+        }
120
+        else {
120 121
             $args['orderby'] = 'relevance';
121 122
             $args['posts_per_page'] = 10;
122 123
             $args['s'] = $searchTerm;
Please login to merge, or discard this patch.
activate.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -120,7 +120,8 @@
 block discarded – undo
120 120
                 sprintf($messages[1], $messages[3].' '.$this->versions['php']),
121 121
                 sprintf($messages[2], PHP_VERSION).'</p><p>'.$rollbackMessage
122 122
             );
123
-        } elseif (!$this->isWpValid()) {
123
+        }
124
+        elseif (!$this->isWpValid()) {
124 125
             printf($noticeTemplate,
125 126
                 sprintf($messages[0], $pluginName),
126 127
                 sprintf($messages[1], $messages[4].' '.$this->versions['wordpress']),
Please login to merge, or discard this patch.
helpers.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -100,7 +100,8 @@
 block discarded – undo
100 100
     if (1 == count($vars)) {
101 101
         $value = htmlspecialchars(print_r($vars[0], true), ENT_QUOTES, 'UTF-8');
102 102
         printf('<div class="glsr-debug"><pre>%s</pre></div>', $value);
103
-    } else {
103
+    }
104
+    else {
104 105
         echo '<div class="glsr-debug-group">';
105 106
         foreach ($vars as $var) {
106 107
             glsr_debug($var);
Please login to merge, or discard this patch.
plugin/Modules/Upgrader.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -49,7 +49,8 @@
 block discarded – undo
49 49
         if ($this->currentVersion !== glsr()->version) {
50 50
             $this->setReviewCounts();
51 51
             $this->updateVersionFrom($this->currentVersion);
52
-        } elseif (!glsr(OptionManager::class)->get('last_review_count', false)) {
52
+        }
53
+        elseif (!glsr(OptionManager::class)->get('last_review_count', false)) {
53 54
             $this->setReviewCounts();
54 55
         }
55 56
     }
Please login to merge, or discard this patch.
plugin/Handlers/TogglePinned.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -19,7 +19,8 @@
 block discarded – undo
19 19
         if (is_null($command->pinned)) {
20 20
             $meta = glsr(Database::class)->get($command->id, 'pinned');
21 21
             $command->pinned = !wp_validate_boolean($meta);
22
-        } else {
22
+        }
23
+        else {
23 24
             $notice = $command->pinned
24 25
                 ? __('Review pinned.', 'site-reviews')
25 26
                 : __('Review unpinned.', 'site-reviews');
Please login to merge, or discard this patch.
plugin/Modules/Html/Partials/SiteReviews.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -194,7 +194,8 @@
 block discarded – undo
194 194
         $dateFormat = $this->getOption('settings.reviews.date.format', 'default');
195 195
         if ('relative' == $dateFormat) {
196 196
             $date = glsr(Date::class)->relative($value);
197
-        } else {
197
+        }
198
+        else {
198 199
             $format = 'custom' == $dateFormat
199 200
                 ? $this->getOption('settings.reviews.date.custom', 'M j, Y')
200 201
                 : glsr(OptionManager::class)->getWP('date_format', 'F j, Y');
Please login to merge, or discard this patch.
plugin/Controllers/SettingsController.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -108,7 +108,8 @@
 block discarded – undo
108 108
                 constant($integrationClass.'::PLUGIN_NAME')
109 109
             ));
110 110
             return false;
111
-        } elseif (!glsr($integrationClass)->isSupported()) {
111
+        }
112
+        elseif (!glsr($integrationClass)->isSupported()) {
112 113
             glsr(Notice::class)->addError(sprintf(
113 114
                 __('Please update the %s plugin to v%s or greater to enable integration.', 'site-reviews'),
114 115
                 constant($integrationClass.'::PLUGIN_NAME'),
Please login to merge, or discard this patch.
plugin/Modules/Rebusify.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -101,7 +101,8 @@
 block discarded – undo
101 101
     {
102 102
         if (is_wp_error($response)) {
103 103
             $this->message = $response->get_error_message();
104
-        } else {
104
+        }
105
+        else {
105 106
             $responseBody = wp_remote_retrieve_body($response);
106 107
             $responseCode = wp_remote_retrieve_response_code($response);
107 108
             $responseData = (array) json_decode($responseBody, true);
Please login to merge, or discard this patch.