diff --git a/core/dictionary.cpp b/core/dictionary.cpp index 1b431f9ec9e..48e65c734fb 100644 --- a/core/dictionary.cpp +++ b/core/dictionary.cpp @@ -61,7 +61,7 @@ Variant &Dictionary::operator[](const Variant &p_key) { const Variant &Dictionary::operator[](const Variant &p_key) const { - return ((const OrderedHashMap *)&_p->variant_map)->operator[](p_key); + return _p->variant_map[p_key]; } const Variant *Dictionary::getptr(const Variant &p_key) const {