From 68025cce8abd5907415d44c0ed09f6c4ba099c91 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9as=20Lundgren?= Date: Fri, 20 Jan 2023 15:26:29 +0100 Subject: [PATCH] fix: catching empty arrays due to loose comparison --- src/Validator.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Validator.php b/src/Validator.php index e7efac4..0bdc3ae 100644 --- a/src/Validator.php +++ b/src/Validator.php @@ -43,7 +43,7 @@ public static function validateMinMaxTol($begin, $end, $tol) { } public static function validateWidths($widths) { - if ($widths == NULL) { + if (is_null($widths)) { throw new \InvalidArgumentException("`widths` array cannot be `null`"); }