Fixing user profile edit to display updated information after save.
This commit is contained in:
parent
7b792c9541
commit
ddd46ba9ad
|
@ -57,7 +57,6 @@ class UserController extends Controller
|
|||
public function profile()
|
||||
{
|
||||
$user = $_SESSION['phpci_user'];
|
||||
$values = $user->getDataArray();
|
||||
|
||||
if ($this->request->getMethod() == 'POST') {
|
||||
$name = $this->getParam('name', null);
|
||||
|
@ -65,8 +64,11 @@ class UserController extends Controller
|
|||
$password = $this->getParam('password', null);
|
||||
|
||||
$_SESSION['phpci_user'] = $this->userService->updateUser($user, $name, $email, $password);
|
||||
$user = $_SESSION['phpci_user'];
|
||||
}
|
||||
|
||||
$values = $user->getDataArray();
|
||||
|
||||
$form = new Form();
|
||||
$form->setAction(PHPCI_URL.'user/profile');
|
||||
$form->setMethod('POST');
|
||||
|
|
Loading…
Reference in a new issue