Why is it even running JavaScript? That too for mission critical application.
Sequence scripts are written in js.
Execution of sequences, hardware control, resource management, and everything not sequence markup is not. The sequences are not flight software (imho), but the interpreter is.