From 95ef3267bb90c7322dec41e1dd23d6ae4fa8ffda Mon Sep 17 00:00:00 2001 From: Jos van den Oever Date: Thu, 15 Nov 2012 10:19:50 +0100 Subject: [PATCH] Throw and exception in the assert. --- webodf/lib/runtime.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/webodf/lib/runtime.js b/webodf/lib/runtime.js index e92a7b7f..a29bbe9b 100644 --- a/webodf/lib/runtime.js +++ b/webodf/lib/runtime.js @@ -466,10 +466,11 @@ function BrowserRuntime(logoutput) { */ function assert(condition, message, callback) { if (!condition) { - log("alert", "ASSERTION FAILED:\n"+message); + log("alert", "ASSERTION FAILED:\n" + message); if (callback) { callback(); } + throw message; // interrupt execution and provide a backtrace } }