You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-12-06 17:25:19 +00:00
Merge pull request #51593 from KoBeWi/if
Prevent crash when awaiting in a getter/setter
This commit is contained in:
@@ -2385,7 +2385,9 @@ GDScriptParser::ExpressionNode *GDScriptParser::parse_await(ExpressionNode *p_pr
|
|||||||
}
|
}
|
||||||
await->to_await = element;
|
await->to_await = element;
|
||||||
|
|
||||||
current_function->is_coroutine = true;
|
if (current_function) { // Might be null in a getter or setter.
|
||||||
|
current_function->is_coroutine = true;
|
||||||
|
}
|
||||||
|
|
||||||
return await;
|
return await;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user