Skip to content

Commit

Permalink
Merge pull request #21 from slamdata/infallible-cancel
Browse files Browse the repository at this point in the history
Don't allow cancelling to fail
  • Loading branch information
jdegoes committed Apr 20, 2015
2 parents 3fbe708 + e15ba78 commit c7b24ce
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Network/HTTP/Affjax.purs
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ foreign import _cancelAjax
"""
function _cancelAjax (xhr, cancelError, errback, callback) {
return function () {
try { xhr.abort(); } catch (e) { return errback(e)(); }
try { xhr.abort(); } catch (e) { return callback(false)(); }
return callback(true)();
};
};
Expand Down

0 comments on commit c7b24ce

Please sign in to comment.