mirror of
https://github.com/wallabag/wallabag.git
synced 2024-12-17 02:39:24 +01:00
Use alias to get container parameters
This commit is contained in:
parent
d6ba77e888
commit
67c99849ae
@ -133,10 +133,10 @@ class ConfigController extends Controller
|
||||
$userManager->updateUser($newUser, true);
|
||||
|
||||
$config = new Config($newUser);
|
||||
$config->setTheme($this->container->getParameter('wallabag_core.theme'));
|
||||
$config->setItemsPerPage($this->container->getParameter('wallabag_core.items_on_page'));
|
||||
$config->setRssLimit($this->container->getParameter('wallabag_core.rss_limit'));
|
||||
$config->setLanguage($this->container->getParameter('wallabag_core.language'));
|
||||
$config->setTheme($this->getParameter('wallabag_core.theme'));
|
||||
$config->setItemsPerPage($this->getParameter('wallabag_core.items_on_page'));
|
||||
$config->setRssLimit($this->getParameter('wallabag_core.rss_limit'));
|
||||
$config->setLanguage($this->getParameter('wallabag_core.language'));
|
||||
|
||||
$em->persist($config);
|
||||
|
||||
|
@ -84,7 +84,7 @@ class RssController extends Controller
|
||||
$pagerAdapter = new DoctrineORMAdapter($qb->getQuery());
|
||||
$entries = new Pagerfanta($pagerAdapter);
|
||||
|
||||
$perPage = $user->getConfig()->getRssLimit() ?: $this->container->getParameter('rss_limit');
|
||||
$perPage = $user->getConfig()->getRssLimit() ?: $this->getParameter('wallabag_core.rss_limit');
|
||||
$entries->setMaxPerPage($perPage);
|
||||
|
||||
return $this->render('WallabagCoreBundle:Entry:entries.xml.twig', array(
|
||||
|
Loading…
Reference in New Issue
Block a user