Total Complexity | 1 |
Total Lines | 15 |
Duplicated Lines | 0 % |
Coverage | 100% |
Changes | 0 |
1 | <?php |
||
25 | class Md5Hasher implements HasherInterface |
||
26 | { |
||
27 | /** |
||
28 | * {@inheritDoc} |
||
29 | * |
||
30 | * 8 hexits = 32bit, which also allows us to forego having to check whether |
||
31 | * it is over PHP_INT_MAX. |
||
32 | * |
||
33 | * The substring is converted to an int since hex strings sometimes get |
||
34 | * treated as ints if all digits are ints and this results in unexpected |
||
35 | * sorting order. |
||
36 | */ |
||
37 | 2 | public function hash(string $string): int |
|
42 |