Passed
Push — feature/rebusify ( 0fe5b2...103190 )
by Paul
08:37 queued 03:55
created
plugin/Controllers/ReviewController.php 1 patch
Braces   +10 added lines, -9 removed lines patch added patch discarded remove patch
@@ -22,7 +22,7 @@  discard block
 block discarded – undo
22 22
 	 * @action set_object_terms
23 23
 	 */
24 24
     public function onAfterChangeCategory($postId, $terms, $newTTIds, $taxonomy, $append, $oldTTIds)
25
-	{
25
+    {
26 26
         sort($newTTIds);
27 27
         sort($oldTTIds);
28 28
         if ($newTTIds === $oldTTIds || !$this->isReviewPostId($postId)) {
@@ -48,14 +48,15 @@  discard block
 block discarded – undo
48 48
 	 * @action transition_post_status
49 49
 	 */
50 50
     public function onAfterChangeStatus($newStatus, $oldStatus, $post)
51
-	{
51
+    {
52 52
         if (Application::POST_TYPE != glsr_get($post, 'post_type') || in_array($oldStatus, ['new', $newStatus])) {
53 53
             return;
54 54
 		}
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
 	}
@@ -65,7 +66,7 @@  discard block
 block discarded – undo
65 66
 	 * @action site-reviews/review/created
66 67
 	 */
67 68
     public function onAfterCreate(Review $review)
68
-	{
69
+    {
69 70
         if ('publish' !== $review->status) {
70 71
             return;
71 72
         }
@@ -78,7 +79,7 @@  discard block
 block discarded – undo
78 79
 	 * @action before_delete_post
79 80
 	 */
80 81
     public function onBeforeDelete($postId)
81
-	{
82
+    {
82 83
         if (!$this->isReviewPostId($postId)) {
83 84
             return;
84 85
         }
@@ -95,7 +96,7 @@  discard block
 block discarded – undo
95 96
 	 * @action update_postmeta
96 97
 	 */
97 98
     public function onBeforeUpdate($metaId, $postId, $metaKey, $metaValue)
98
-	{
99
+    {
99 100
         if (!$this->isReviewPostId($postId)) {
100 101
             return;
101 102
         }
@@ -116,7 +117,7 @@  discard block
 block discarded – undo
116 117
 	 * @return void
117 118
 	 */
118 119
     public function onBeforeChangeAssignedTo(Review $review, $assignedTo)
119
-	{
120
+    {
120 121
         glsr(CountsManager::class)->decreasePostCounts($review);
121 122
 		$review->assigned_to = $assignedTo;
122 123
         glsr(CountsManager::class)->increasePostCounts($review);
@@ -127,7 +128,7 @@  discard block
 block discarded – undo
127 128
 	 * @return void
128 129
 	 */
129 130
     public function onBeforeChangeRating(Review $review, $rating)
130
-	{
131
+    {
131 132
         glsr(CountsManager::class)->decrease($review);
132 133
 		$review->rating = $rating;
133 134
         glsr(CountsManager::class)->increase($review);
@@ -138,7 +139,7 @@  discard block
 block discarded – undo
138 139
 	 * @return void
139 140
 	 */
140 141
     public function onBeforeChangeReviewType(Review $review, $reviewType)
141
-	{
142
+    {
142 143
         glsr(CountsManager::class)->decrease($review);
143 144
 		$review->review_type = $reviewType;
144 145
         glsr(CountsManager::class)->increase($review);
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/HelperTraits/Arr.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -221,7 +221,8 @@
 block discarded – undo
221 221
                 if ($flattenValue) {
222 222
                     $value = '['.implode(', ', $value).']';
223 223
                 }
224
-            } elseif (is_array($value)) {
224
+            }
225
+            elseif (is_array($value)) {
225 226
                 $result = array_merge($result, $this->flattenArray($value, $flattenValue, $newKey));
226 227
                 continue;
227 228
             }
Please login to merge, or discard this patch.
plugin/Actions.php 1 patch
Braces   +2 added lines, -1 removed lines patch added patch discarded remove patch
@@ -33,7 +33,8 @@
 block discarded – undo
33 33
     protected $taxonomy;
34 34
     protected $welcome;
35 35
 
36
-    public function __construct(Application $app ) {
36
+    public function __construct(Application $app )
37
+    {
37 38
         $this->app = $app;
38 39
         $this->admin = $app->make(AdminController::class);
39 40
         $this->blocks = $app->make(BlocksController::class);
Please login to merge, or discard this patch.