Passed
Push — Showing-Posts ( 80fb19...3afe89 )
by Stone
01:57
created
App/Controllers/Admin/Post.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -174,10 +174,12 @@
 block discarded – undo
174 174
             $this->alertBox->setAlert("empty slug not allowed", "error");
175 175
         }
176 176
 
177
-        if ($postSlug != $originalPostSlug) //if the slug has been updated
177
+        if ($postSlug != $originalPostSlug) {
178
+            //if the slug has been updated
178 179
         {
179 180
             if (!$slugModel->isUnique($postSlug, "posts", "posts_slug")) {
180 181
                 $error = true;
182
+        }
181 183
                 $originalPostSlug = $slugModel->getSlugFromId($postId, "posts", "idposts", "posts_slug");
182 184
                 $this->alertBox->setAlert("Slug not unique", "error");
183 185
             }
Please login to merge, or discard this patch.