]> git.immae.eu Git - github/wallabag/wallabag.git/blobdiff - src/Wallabag/ApiBundle/Controller/WallabagRestController.php
fix updating entry status through API
[github/wallabag/wallabag.git] / src / Wallabag / ApiBundle / Controller / WallabagRestController.php
index d0a35013850c3794c6582205fd0befc5b1c46620..a590dda1f9479bc1ae13c62d67b49ad12fa14a07 100644 (file)
@@ -126,13 +126,9 @@ class WallabagRestController extends FOSRestController
             $this->get('wallabag_core.content_proxy')->assignTagsToEntry($entry, $tags);
         }
 
-        if (true === (bool) $isStarred) {
-            $entry->setStarred(true);
-        }
+        $entry->setStarred((bool) $isStarred);
 
-        if (true === (bool) $isArchived) {
-            $entry->setArchived(true);
-        }
+        $entry->setArchived((bool) $isArchived);
 
         $em = $this->getDoctrine()->getManager();
         $em->persist($entry);