X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=src%2FWallabag%2FImportBundle%2FController%2FWallabagV1Controller.php;h=8b27144be4c2b1ee33e9e21d864c20283707891f;hb=c10fcb3bbbd4ef14edd9a862ee18c895d92e30ae;hp=35fe620f8adaf83cbbb37e0953bbb34a2d83eafe;hpb=1d76102a240c2596832848128a7b9cf5aa2050dd;p=github%2Fwallabag%2Fwallabag.git diff --git a/src/Wallabag/ImportBundle/Controller/WallabagV1Controller.php b/src/Wallabag/ImportBundle/Controller/WallabagV1Controller.php index 35fe620f..8b27144b 100644 --- a/src/Wallabag/ImportBundle/Controller/WallabagV1Controller.php +++ b/src/Wallabag/ImportBundle/Controller/WallabagV1Controller.php @@ -21,12 +21,14 @@ class WallabagV1Controller extends Controller if ($form->isValid()) { $file = $form->get('file')->getData(); + $markAsRead = $form->get('mark_as_read')->getData(); $name = $this->getUser()->getId().'.json'; if (in_array($file->getClientMimeType(), $this->getParameter('wallabag_import.allow_mimetypes')) && $file->move($this->getParameter('wallabag_import.resource_dir'), $name)) { $res = $wallabag ->setUser($this->getUser()) ->setFilepath($this->getParameter('wallabag_import.resource_dir').'/'.$name) + ->setMarkAsRead($markAsRead) ->import(); $message = 'Import failed, please try again.';