Merge pull request #12780 from karroffel/dictionary-crash

fix dictionary constant access crash
This commit is contained in:
Rémi Verschelde 2017-11-09 16:30:07 +01:00 committed by GitHub
commit c7cd89c29f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -61,7 +61,7 @@ Variant &Dictionary::operator[](const Variant &p_key) {
const Variant &Dictionary::operator[](const Variant &p_key) const {
return ((const OrderedHashMap<Variant, Variant, _DictionaryVariantHash> *)&_p->variant_map)->operator[](p_key);
return _p->variant_map[p_key];
}
const Variant *Dictionary::getptr(const Variant &p_key) const {