From 9e3a79d0f6c1f92c66ec5bddb6e64fc688f595af Mon Sep 17 00:00:00 2001 From: hoangkhacphuc Date: Tue, 2 Sep 2025 02:01:03 +0700 Subject: [PATCH] fix: update return type of throwOrNull method to mixed --- src/EnumValueResolver.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/EnumValueResolver.php b/src/EnumValueResolver.php index 1f2acff..84d7c6d 100644 --- a/src/EnumValueResolver.php +++ b/src/EnumValueResolver.php @@ -26,7 +26,7 @@ public static function getValueFromInstance(UnitEnum|BackedEnum $enum): int|stri return $enum->name; } - protected static function throwOrNull(mixed $name, bool $throw = true): null + protected static function throwOrNull(mixed $name, bool $throw = true): mixed { if ($throw) { throw static::invalidValueException($name);