mirror of
https://github.com/Redot-Engine/redot-engine.git
synced 2025-12-06 15:21:56 -05:00
fix not beeing able to open empty scripts
This commit is contained in:
@@ -1557,11 +1557,7 @@ ScriptTextEditor::ScriptTextEditor() {
|
|||||||
|
|
||||||
static ScriptEditorBase *create_editor(const Ref<Script> &p_script) {
|
static ScriptEditorBase *create_editor(const Ref<Script> &p_script) {
|
||||||
|
|
||||||
if (p_script->has_source_code()) {
|
return memnew(ScriptTextEditor);
|
||||||
return memnew(ScriptTextEditor);
|
|
||||||
}
|
|
||||||
|
|
||||||
return NULL;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScriptTextEditor::register_editor() {
|
void ScriptTextEditor::register_editor() {
|
||||||
|
|||||||
Reference in New Issue
Block a user