diff options
Diffstat (limited to 'src/Wallabag/CoreBundle/Command/InstallCommand.php')
-rw-r--r-- | src/Wallabag/CoreBundle/Command/InstallCommand.php | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/Wallabag/CoreBundle/Command/InstallCommand.php b/src/Wallabag/CoreBundle/Command/InstallCommand.php index 1bd76ae3..6ebbd93c 100644 --- a/src/Wallabag/CoreBundle/Command/InstallCommand.php +++ b/src/Wallabag/CoreBundle/Command/InstallCommand.php | |||
@@ -8,7 +8,7 @@ use Symfony\Component\Console\Input\InputOption; | |||
8 | use Symfony\Component\Console\Input\ArrayInput; | 8 | use Symfony\Component\Console\Input\ArrayInput; |
9 | use Symfony\Component\Console\Output\OutputInterface; | 9 | use Symfony\Component\Console\Output\OutputInterface; |
10 | use Symfony\Component\Console\Output\NullOutput; | 10 | use Symfony\Component\Console\Output\NullOutput; |
11 | use Wallabag\CoreBundle\Entity\User; | 11 | use Wallabag\UserBundle\Entity\User; |
12 | use Wallabag\CoreBundle\Entity\Config; | 12 | use Wallabag\CoreBundle\Entity\Config; |
13 | 13 | ||
14 | class InstallCommand extends ContainerAwareCommand | 14 | class InstallCommand extends ContainerAwareCommand |
@@ -188,9 +188,10 @@ class InstallCommand extends ContainerAwareCommand | |||
188 | 188 | ||
189 | $em = $this->getContainer()->get('doctrine.orm.entity_manager'); | 189 | $em = $this->getContainer()->get('doctrine.orm.entity_manager'); |
190 | 190 | ||
191 | $user = new User(); | 191 | $userManager = $this->getContainer()->get('fos_user.user_manager'); |
192 | $user = $userManager->createUser(); | ||
192 | $user->setUsername($dialog->ask($this->defaultOutput, '<question>Username</question> <comment>(default: wallabag)</comment> :', 'wallabag')); | 193 | $user->setUsername($dialog->ask($this->defaultOutput, '<question>Username</question> <comment>(default: wallabag)</comment> :', 'wallabag')); |
193 | $user->setPassword($dialog->ask($this->defaultOutput, '<question>Password</question> <comment>(default: wallabag)</comment> :', 'wallabag')); | 194 | $user->setPlainPassword($dialog->ask($this->defaultOutput, '<question>Password</question> <comment>(default: wallabag)</comment> :', 'wallabag')); |
194 | $user->setEmail($dialog->ask($this->defaultOutput, '<question>Email:</question>', '')); | 195 | $user->setEmail($dialog->ask($this->defaultOutput, '<question>Email:</question>', '')); |
195 | $user->setEnabled(true); | 196 | $user->setEnabled(true); |
196 | 197 | ||