@@ -101,7 +101,8 @@ |
||
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); |
@@ -55,7 +55,8 @@ |
||
55 | 55 | $review = glsr_get_review($post); |
56 | 56 | if ('publish' == $post->post_status) { |
57 | 57 | glsr(CountsManager::class)->increase($review); |
58 | - } else { |
|
58 | + } |
|
59 | + else { |
|
59 | 60 | glsr(CountsManager::class)->decrease($review); |
60 | 61 | } |
61 | 62 | } |
@@ -158,7 +158,8 @@ |
||
158 | 158 | $counts = []; |
159 | 159 | if ($this->isMixedCount($args)) { |
160 | 160 | $counts = [$this->buildCounts($args)]; // force query the database |
161 | - } else { |
|
161 | + } |
|
162 | + else { |
|
162 | 163 | foreach ($args['post_ids'] as $postId) { |
163 | 164 | $counts[] = $this->getPostCounts($postId); |
164 | 165 | } |
@@ -64,7 +64,8 @@ |
||
64 | 64 | if ($flattenValue) { |
65 | 65 | $value = '['.implode(', ', $value).']'; |
66 | 66 | } |
67 | - } elseif (is_array($value)) { |
|
67 | + } |
|
68 | + elseif (is_array($value)) { |
|
68 | 69 | $result = array_merge($result, static::flattenArray($value, $flattenValue, $newKey)); |
69 | 70 | continue; |
70 | 71 | } |
@@ -51,7 +51,8 @@ discard block |
||
51 | 51 | } |
52 | 52 | if ('F' === $rebusifyProductType && 'yes' === glsr_get_option('general.rebusify')) { |
53 | 53 | $button = $this->buildUpgradeButton(); |
54 | - } else { |
|
54 | + } |
|
55 | + else { |
|
55 | 56 | $button = $this->buildCreateButton(); |
56 | 57 | } |
57 | 58 | $context['field'].= $button; |
@@ -229,7 +230,8 @@ discard block |
||
229 | 230 | ); |
230 | 231 | if ($rebusify->success) { |
231 | 232 | update_option($this->rebusifyKey, Arr::get($rebusify->response, 'producttype')); |
232 | - } else { |
|
233 | + } |
|
234 | + else { |
|
233 | 235 | delete_option($this->rebusifyKey); |
234 | 236 | $settings = Arr::set($settings, $this->enabledKey, 'no'); |
235 | 237 | glsr(Notice::class)->addError(sprintf( |
@@ -134,7 +134,8 @@ |
||
134 | 134 | ['context' => $this->email['template-tags']], |
135 | 135 | $this->email['template'] |
136 | 136 | ); |
137 | - } elseif ($this->email['template']) { |
|
137 | + } |
|
138 | + elseif ($this->email['template']) { |
|
138 | 139 | $message = glsr(Template::class)->build('templates/'.$this->email['template'], [ |
139 | 140 | 'context' => $this->email['template-tags'], |
140 | 141 | ]); |