Skip to content

Commit b80c8ef

Browse files
authored
Merge pull request #161 from Kharhamel/passwordHash
Password hash
2 parents 64bb866 + 10c076c commit b80c8ef

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

generated/password.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@
9797
* algorithm, will result
9898
* in the password parameter being truncated to a
9999
* maximum length of 72 characters.
100-
* @param int $algo A password algorithm constant denoting the algorithm to use when hashing the password.
100+
* @param int|string|null $algo A password algorithm constant denoting the algorithm to use when hashing the password.
101101
* @param array $options An associative array containing options. See the password algorithm constants for documentation on the supported options for each algorithm.
102102
*
103103
* If omitted, a random salt will be created and the default cost will be
@@ -111,7 +111,7 @@
111111
* @throws PasswordException
112112
*
113113
*/
114-
function password_hash(string $password, int $algo, array $options = null): string
114+
function password_hash(string $password, $algo, array $options = null): string
115115
{
116116
error_clear_last();
117117
if ($options !== null) {

generator/src/PhpStanFunctions/CustomPhpStanFunctionMap.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@
1212
'gmp_random_seed' => ['void', 'seed'=>'GMP|string|int'], //gmp_random_seed doesn't return
1313
'imageconvolution' => ['bool', 'src_im'=>'resource', 'matrix3x3'=>'array', 'div'=>'float', 'offset'=>'float'], //imageconvolution return a bool
1414
'iptcembed' => ['string|bool', 'iptcdata'=>'string', 'jpeg_file_name'=>'string', 'spool='=>'int'], //iptcembed return either a string, true or false
15+
'password_hash' => ['string|false', 'password'=>'string', 'algo'=>'int|string|null', 'options='=>'array'],
1516
];

0 commit comments

Comments
 (0)