]> git.immae.eu Git - github/wallabag/wallabag.git/commitdiff
review from @j0k3r
authorNicolas Lœuillet <nicolas@loeuillet.org>
Tue, 10 Feb 2015 11:12:44 +0000 (12:12 +0100)
committerNicolas Lœuillet <nicolas@loeuillet.org>
Tue, 10 Feb 2015 11:12:44 +0000 (12:12 +0100)
src/Wallabag/CoreBundle/Controller/WallabagRestController.php

index 96d2529a43c7251c0c1d0dd0ba04b6644ef4a740..ddb1f8a567984e49a488957dd28b1dc901148719 100644 (file)
@@ -8,7 +8,6 @@ use Symfony\Component\HttpFoundation\Request;
 use Symfony\Component\HttpKernel\Exception\NotFoundHttpException;
 use Wallabag\CoreBundle\Entity\Entry;
 use Wallabag\CoreBundle\Entity\Tags;
-use Wallabag\CoreBundle\Entity\User;
 use Wallabag\CoreBundle\Service\Extractor;
 
 class WallabagRestController extends Controller
@@ -109,7 +108,7 @@ class WallabagRestController extends Controller
         $url = $request->request->get('url');
 
         $content = Extractor::extract($url);
-        $entry = new Entry($this->getUser()->getId());
+        $entry = new Entry($this->getUser());
         $entry->setUrl($url);
         $entry->setTitle($request->request->get('title') ?: $content->getTitle());
         $entry->setContent($content->getBody());