Force empty to be 0 for in_mask #1180

This commit is contained in:
Nabeel Shahzad 2021-05-19 10:22:15 -04:00
parent 77a4acb569
commit dff4273c72

View File

@ -30,6 +30,10 @@ if (!function_exists('in_mask')) {
*/
function in_mask($mask, $value)
{
if (empty($mask)) {
$mask = 0;
}
return ($mask & $value) === $value;
}
}