return 1;
}
} else {
- $users = $this->getDoctrine()->getRepository('WallabagUserBundle:User')->findAll();
+ $users = $this->get('wallabag_user.user_repository')->findAll();
$output->writeln(sprintf('Cleaning through %d user accounts', count($users)));
private function cleanDuplicates(User $user)
{
$em = $this->getContainer()->get('doctrine.orm.entity_manager');
- $repo = $this->getDoctrine()->getRepository('WallabagCoreBundle:Entry');
+ $repo = $this->get('wallabag_core.entry_repository');
$entries = $repo->getAllEntriesIdAndUrl($user->getId());
*/
private function getUser($username)
{
- return $this->getDoctrine()->getRepository('WallabagUserBundle:User')->findOneByUserName($username);
+ return $this->get('wallabag_user.user_repository')->findOneByUserName($username);
}
private function getDoctrine()