Skip to content

Commit 270827b

Browse files
skerbisCopilot
andauthored
Update lib/EmailObfuscator.php
Co-authored-by: Copilot <[email protected]>
1 parent 5823579 commit 270827b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/EmailObfuscator.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ private static function encryptEmailData($data, $method, $context = '') {
270270
for ($i = 0; $i < strlen($fullString); $i++) {
271271
$char = ord($fullString[$i]);
272272
$hash = (($hash << 5) - $hash) + $char;
273-
$hash = ($hash << 32) >> 32; // Keep as 32-bit signed integer (cross-platform)
273+
$hash = $hash & 0xFFFFFFFF; // Keep as 32-bit unsigned integer (cross-platform)
274274
}
275275
// Convert to hex and take first 16 characters
276276
$hashHex = dechex(sprintf('%u', $hash));

0 commit comments

Comments
 (0)