Skip to content

Commit

Permalink
Move the variable assignment inside the else-if block
Browse files Browse the repository at this point in the history
Signed-off-by: Deven Bansod <devenbansod.bits@gmail.com>
  • Loading branch information
devenbansod authored and lem9 committed Dec 19, 2015
1 parent 187aa09 commit 996a6b6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions user_password.php
Expand Up @@ -180,6 +180,9 @@ function PMA_changePassword($password, $message, $change_password_message)
$value = 0;
}
$GLOBALS['dbi']->tryQuery('SET `old_passwords` = ' . $value . ';');

$sql_query = 'SET password = '
. (($password == '') ? '\'\'' : $hashing_function . '(\'***\')');
}

PMA_changePassUrlParamsAndSubmitQuery(
Expand Down

2 comments on commit 996a6b6

@devenbansod
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @lem9 , we wouln't need this I guess, since now both the assignments on L159-160 and L184-185 are same, which is not required.
The one on L159-160 is meant to be the base case for everyone, except the newest MySQL 5.7.6+ versions which provides for newer ALTER USER ... syntax.

The QA_4_5 branch is fine.

@lem9
Copy link
Contributor

@lem9 lem9 commented on 996a6b6 Dec 20, 2015

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @devenbansod, lines 183-185 now removed.

Please sign in to comment.