replacing old_value check with laravel's array_get