From 51a15609b3bb0635e5cbea8511d983e2c5a97fe7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nicolas=20L=C5=93uillet?= Date: Mon, 2 May 2016 12:49:23 +0200 Subject: Set the title via POST /api/entries Fix #2009 --- src/Wallabag/ApiBundle/Controller/WallabagRestController.php | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/Wallabag/ApiBundle/Controller/WallabagRestController.php') diff --git a/src/Wallabag/ApiBundle/Controller/WallabagRestController.php b/src/Wallabag/ApiBundle/Controller/WallabagRestController.php index 316d45be..5202c524 100644 --- a/src/Wallabag/ApiBundle/Controller/WallabagRestController.php +++ b/src/Wallabag/ApiBundle/Controller/WallabagRestController.php @@ -109,6 +109,7 @@ class WallabagRestController extends FOSRestController $this->validateAuthentication(); $url = $request->request->get('url'); + $title = $request->request->get('title'); $isArchived = (int) $request->request->get('archive'); $isStarred = (int) $request->request->get('starred'); @@ -121,6 +122,10 @@ class WallabagRestController extends FOSRestController ); } + if (!is_null($title)) { + $entry->setTitle($title); + } + $tags = $request->request->get('tags', ''); if (!empty($tags)) { $this->get('wallabag_core.content_proxy')->assignTagsToEntry($entry, $tags); -- cgit v1.2.3