Skip to content

Commit

Permalink
Fixes #71. Signup now working correctly.
Browse files Browse the repository at this point in the history
  • Loading branch information
thisismeonmounteverest committed Aug 26, 2018
1 parent 2c9ab96 commit 9722597
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 21 deletions.
4 changes: 4 additions & 0 deletions build/signup/signup.ctrl.php
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,10 @@ public function signupFormCallback($args, $action, $mem_redirect, $mem_resend)
$vars = $this->_session->get('SignupBWVars');
$request = $args->request;

if (!isset($request[1])) {
$request[1] = 1;
}

if (isset($request[1])) {
$step = intval($request[1]);
$model = new SignupModel();
Expand Down
27 changes: 6 additions & 21 deletions build/signup/signup.model.php
Original file line number Diff line number Diff line change
Expand Up @@ -444,11 +444,12 @@ public function registerBWMember($vars) {
$stmt->bindParam(5, $vars['genderhidden']);
$stmt->bindParam(6, $vars['iso_date']);
$stmt->bindParam(7, $vars['agehidden']);
$stmt->bindParam(8, $vars['firstname']);
$stmt->bindParam(9, $vars['secondname']);
$stmt->bindParam(10, $vars['lastname']);
$stmt->bindParam(11, $vars['email']);
$stmt->bindParam(12, \Member::MEMBER_EMAIL_HIDDEN);
$stmt->bindParam(8, $vars['email']);
$stmt->bindParam(9, $vars['firstname']);
$stmt->bindParam(10, $vars['secondname']);
$stmt->bindParam(11, $vars['lastname']);
$hide = \Member::MEMBER_EMAIL_HIDDEN;
$stmt->bindParam(12, $hide);

$res = $stmt->execute();
$memberID = $stmt->insertId();
Expand Down Expand Up @@ -482,22 +483,6 @@ public function registerBWMember($vars) {
$memberEntity->update();
$memberEntity->setPassword($vars['password']);

// ********************************************************************
// e-mail, names/members
// ********************************************************************
$query = '
UPDATE
`members`
SET
`Email`=' . $cryptedfieldsEmail . ',
`FirstName`=' . $cryptedfieldsFirstname . ',
`SecondName`=' . $cryptedfieldsSecondname . ',
`LastName`=' . $cryptedfieldsLastname . '
WHERE
`id` = ' . $memberID;

$this->dao->query($query);

// ********************************************************************
// address/addresses
// ********************************************************************
Expand Down

0 comments on commit 9722597

Please sign in to comment.