1
0
mirror of https://github.com/godotengine/godot.git synced 2026-01-04 19:21:46 +00:00

Prevent null crash when datatype not resolved

This commit is contained in:
Francois Belair
2022-09-23 11:13:57 -04:00
parent f74491fdee
commit 03e41d21e0

View File

@@ -4001,7 +4001,7 @@ String GDScriptParser::DataType::to_string() const {
if (is_meta_type) {
return script_type->get_class_name().operator String();
}
String name = script_type->get_name();
String name = script_type != nullptr ? script_type->get_name() : "";
if (!name.is_empty()) {
return name;
}