diff --git a/src/app/compiler.js b/src/app/compiler.js index 338f0ce324..87407024db 100644 --- a/src/app/compiler.js +++ b/src/app/compiler.js @@ -30,7 +30,8 @@ function Compiler (editor, queryParams, handleGithubCall, updateFiles) { files[utils.fileNameFromKey(editor.getCacheFile())] = input; gatherImports(files, missingInputs, function (input, error) { if (input === null) { - self.event.trigger('compilationFinished', [false, [error], files]); + self.lastCompilationResult = null; + self.event.trigger('compilationFinished', [false, { 'error': error }, files]); } else { var optimize = queryParams.get().optimize; compileJSON(input, optimize ? 1 : 0);