summaryrefslogtreecommitdiff
path: root/js/codeq/prolog.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/codeq/prolog.js')
-rw-r--r--js/codeq/prolog.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/js/codeq/prolog.js b/js/codeq/prolog.js
index 194f6a8..c361b03 100644
--- a/js/codeq/prolog.js
+++ b/js/codeq/prolog.js
@@ -43,9 +43,10 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. */
codeq.loadProblemData(ref, data).then(function (problem) {
enterFun(problem.generalProblemData, data.commonDef, problem.solution);
})
- .fail(function (reason) {
- codeq.log.error('Failed to obtain the problem definition: ' + reason, reason);
- alert('Failed to obtain the problem definition: ' + reason);
+ .fail(function (error) {
+ var message = 'Could not obtain problem definition: ' + error.message;
+ codeq.log.error(message, error);
+ alert(message);
history.back();
})
.done();