checking if JS script is loaded before compiling

avoids crash
This commit is contained in:
Bertrand
2021-02-26 07:45:53 +01:00
parent 39a1d2e17d
commit 8a1ce9f238
+3
View File
@@ -344,10 +344,13 @@ void ScriptingWindow::revertScript()
} }
void ScriptingWindow::recompileScript() void ScriptingWindow::recompileScript()
{
if (currentScript)
{ {
currentScript->scriptText = editor->toPlainText(); currentScript->scriptText = editor->toPlainText();
currentScript->compileScript(); currentScript->compileScript();
} }
}
void ScriptingWindow::clickedLogClear() void ScriptingWindow::clickedLogClear()
{ {