Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Exception in a promise may result in loosing the callback totally #73

Closed
dfahlander opened this issue Mar 13, 2015 · 0 comments
Closed

Comments

@dfahlander
Copy link
Collaborator

The following code will result in that the main promise is never fulfilled:

Dexie.Promise.resolve(null).then(function () {
    throw new Error("apa");
}).then(function () {
    // Should not come here
}).catch(TypeError, function (e) {
    // Should not come here either because the error thrown was not TypeError
}).catch(function (e) {
    // But should come here. But it doesnt!
}).finally(function () {
    // ..and should definitely come here. But it doesnt!
});
dfahlander added a commit that referenced this issue Mar 13, 2015
Issue #71
Issue #72
Issue #73
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant