Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/YOURLS/YOURLS
Browse files Browse the repository at this point in the history
  • Loading branch information
ozh committed Dec 4, 2015
2 parents adb021b + 8c63fb8 commit 542e24b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion includes/functions-auth.php
Expand Up @@ -170,7 +170,7 @@ function yourls_hash_passwords_now( $config_file ) {
// PHP would interpret $ as a variable, so replace it in storage.
$hash = str_replace( '$', '!', $hash );
$quotes = "'" . '"';
$pattern = "/[$quotes]${user}[$quotes]\s*=>\s*[$quotes]" . preg_quote( $password, '-' ) . "[$quotes]/";
$pattern = "/[$quotes]${user}[$quotes]\s*=>\s*[$quotes]" . preg_quote( $password, '/' ) . "[$quotes]/";
$replace = "'$user' => 'phpass:$hash' /* Password encrypted by YOURLS */ ";
$count = 0;
$configdata = preg_replace( $pattern, $replace, $configdata, -1, $count );
Expand Down

0 comments on commit 542e24b

Please sign in to comment.