Compare commits

...

1 Commits

Author SHA1 Message Date
Thomas MONCHICOURT 645cf1f05a Fix : change password 2018-02-08 17:12:00 +01:00
@@ -109,12 +109,17 @@ class CompanyController extends Controller
$this->get('translator')->trans('company.account.save.title')
);
}
$formFactory = $this->container->get('fos_user.change_password.form.factory');
$formPw = $formFactory->createForm();
$formPw->setData($user);
$formPw->handleRequest($request);
if ($formPw->isSubmitted() && $formPw->isValid()) {
$userManager->updateUser($user);
$this->addFlash(
'notice',
$this->get('translator')->trans('company.account.save.title')
);
}
return $this->render('company/my_account.html.twig', [
'form' => $form->createView(),