Ignore missing screen for TurtlebatchCommand

Fixes CODEOCEAN-FRONTEND-47
This commit is contained in:
Sebastian Serth
2023-09-26 00:25:19 +02:00
parent de7f543afe
commit a93ae6117a

View File

@ -32,7 +32,7 @@ CodeOceanEditorTurtle = {
this.showCanvas();
for (var i = 0; i < msg.batch.length; i++) {
var cmd = msg.batch[i];
this.turtlescreen[cmd[0]].apply(this.turtlescreen, cmd[1]);
this.turtlescreen[cmd[0]]?.apply(this.turtlescreen, cmd[1]);
}
},
@ -50,4 +50,4 @@ CodeOceanEditorTurtle = {
}
}
};
};