X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=src%2FWallabag%2FCoreBundle%2FController%2FEntryController.php;h=5c8ecb402f661c31bcabcaaf4dd57070f06dc1da;hb=50f35f0db2be9586205e793f315608eec59c9666;hp=ab50ebdfdf7550f82f09a83e2bf74d64743c3e66;hpb=0447a75b06142afe59a179bb59ee94f1978aa7a9;p=github%2Fwallabag%2Fwallabag.git diff --git a/src/Wallabag/CoreBundle/Controller/EntryController.php b/src/Wallabag/CoreBundle/Controller/EntryController.php index ab50ebdf..5c8ecb40 100644 --- a/src/Wallabag/CoreBundle/Controller/EntryController.php +++ b/src/Wallabag/CoreBundle/Controller/EntryController.php @@ -251,9 +251,9 @@ class EntryController extends Controller /** * Shows random entry depending on the given type. * - * @param Entry $entry + * @param string $type * - * @Route("/{type}/random", name="random_entry", requirements={"_locale": "unread|starred|archive|untagged|all"}) + * @Route("/{type}/random", name="random_entry", requirements={"type": "unread|starred|archive|untagged|all"}) * * @return \Symfony\Component\HttpFoundation\RedirectResponse */ @@ -267,7 +267,7 @@ class EntryController extends Controller $bag->clear(); $bag->add('notice', 'flashes.entry.notice.no_random_entry'); - return $this->redirect($this->generateUrl('homepage')); + return $this->redirect($this->generateUrl($type)); } return $this->redirect($this->generateUrl('view', ['id' => $entry->getId()]));