diff --git a/azure-storage-common/src/Common/Internal/Utilities.php b/azure-storage-common/src/Common/Internal/Utilities.php index 5765e4f5..0747d6ee 100644 --- a/azure-storage-common/src/Common/Internal/Utilities.php +++ b/azure-storage-common/src/Common/Internal/Utilities.php @@ -612,7 +612,7 @@ public static function endsWith($haystack, $needle, $ignoreCase = false) return true; } - return (substr($haystack, -$length) === $needle); + return (substr((string) $haystack, -$length) === $needle); } /**