Fix exposing the error

Using a promise for the setTimeout call is broken in this case, as the error would again be thrown in a promise operation, and so not exposed
This commit is contained in:
Christophe Coevoet 2015-09-02 12:41:21 +02:00
parent bdd64b7141
commit 4875dd17c4

View File

@ -119,9 +119,9 @@ function tick() {
// //
// - __error__ - Error/exception object to be re-thrown to the browser. // - __error__ - Error/exception object to be re-thrown to the browser.
function exposeError(error) { function exposeError(error) {
tick().then(() => { setTimeout(() => {
throw error; throw error;
}); }, 0);
} }
export default { export default {