GDScript: Make check for exposed classes more consistent
Some places were already checking if classes from ClassDB were exposed, while others didn't. This makes the check more consistent to avoid disparities which can lead to crashes.
This commit is contained in:
@@ -6415,7 +6415,7 @@ void GDScriptAnalyzer::resolve_pending_lambda_bodies() {
|
||||
static_context = previous_static_context;
|
||||
}
|
||||
|
||||
bool GDScriptAnalyzer::class_exists(const StringName &p_class) const {
|
||||
bool GDScriptAnalyzer::class_exists(const StringName &p_class) {
|
||||
return ClassDB::class_exists(p_class) && ClassDB::is_class_exposed(p_class);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user