Specify typehint

This commit is contained in:
Lance Pioch 2024-03-17 13:49:14 -04:00
parent 7c0a46deaa
commit 6030a0e890

View File

@ -16,7 +16,7 @@ if (!function_exists('object_get_strict')) {
* Get an object using dot notation. An object key with a value of null is still considered valid * Get an object using dot notation. An object key with a value of null is still considered valid
* and will not trigger the response of a default value (unlike object_get). * and will not trigger the response of a default value (unlike object_get).
*/ */
function object_get_strict(object $object, ?string $key, $default = null): mixed function object_get_strict(object $object, ?string $key, mixed $default = null): mixed
{ {
if (is_null($key) || trim($key) == '') { if (is_null($key) || trim($key) == '') {
return $object; return $object;