From 893f889d74b35bb7330c3ff3d0187042770a4490 Mon Sep 17 00:00:00 2001 From: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com> Date: Sat, 9 Sep 2023 16:11:33 +0200 Subject: [Core] Replace `ERR_FAIL_COND` with `ERR_FAIL_NULL` where applicable --- core/variant/variant_setget.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'core/variant/variant_setget.cpp') diff --git a/core/variant/variant_setget.cpp b/core/variant/variant_setget.cpp index 30fb5d0e9f..05f7abf32c 100644 --- a/core/variant/variant_setget.cpp +++ b/core/variant/variant_setget.cpp @@ -318,7 +318,7 @@ Variant Variant::get_named(const StringName &p_member, bool &r_valid) const { #ifdef DEBUG_ENABLED #define NULL_TEST(m_key) \ - ERR_FAIL_COND(!m_key) + ERR_FAIL_NULL(m_key) #else @@ -1068,7 +1068,7 @@ struct VariantKeyedSetGetObject { } static uint32_t ptr_has(const void *base, const void *key) { const Object *obj = PtrToArg::convert(base); - ERR_FAIL_COND_V(!obj, false); + ERR_FAIL_NULL_V(obj, false); bool valid; obj->getvar(PtrToArg::convert(key), &valid); return valid; @@ -1245,7 +1245,7 @@ void Variant::get_property_list(List *p_list) const { } } else if (type == OBJECT) { Object *obj = get_validated_object(); - ERR_FAIL_COND(!obj); + ERR_FAIL_NULL(obj); obj->get_property_list(p_list); } else { -- cgit v1.2.3