Passed
Push — Showing-Posts ( a59326...b4fc92 )
by Stone
01:47
created
App/Controllers/Admin/Post.php 1 patch
Braces   +3 added lines, -1 removed lines patch added patch discarded remove patch
@@ -196,10 +196,12 @@
 block discarded – undo
196 196
             $this->alertBox->setAlert("empty slug not allowed", "error");
197 197
         }
198 198
 
199
-        if ($postSlug != $originalPostSlug) //if the slug has been updated
199
+        if ($postSlug != $originalPostSlug) {
200
+            //if the slug has been updated
200 201
         {
201 202
             if (!$this->slugModel->isUnique($postSlug, "posts", "posts_slug")) {
202 203
                 $error = true;
204
+        }
203 205
                 $originalPostSlug = $this->slugModel->getSlugFromId($postId, "posts", "idposts", "posts_slug");
204 206
                 $this->alertBox->setAlert("Slug not unique", "error");
205 207
             }
Please login to merge, or discard this patch.