Skip to content

Commit 3c95a7d

Browse files
committed
Update Canonicalizer.php
null !== '' Checking for null is used in particular in the validation
1 parent a12abfa commit 3c95a7d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Util/Canonicalizer.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,6 @@ class Canonicalizer implements CanonicalizerInterface
1515
{
1616
public function canonicalize($string)
1717
{
18-
return mb_convert_case($string, MB_CASE_LOWER, mb_detect_encoding($string));
18+
return null === $string ?: mb_convert_case($string, MB_CASE_LOWER, mb_detect_encoding($string));
1919
}
2020
}

0 commit comments

Comments
 (0)