Override Backbone's trigger with one that catches exceptions

Model operations are vulnerable to exceptions thrown by event handlers.
Because this can interrupt really important data operations, it's better
to let the operation continue and log the error. In all likelihood it's
a view-related problem, and that shouldn't cause any data operation to
fail.

FREEBIE
This commit is contained in:
Scott Nonnenberg 2017-07-19 11:59:08 -07:00
parent 700272cf85
commit cc2c3edaa6
4 changed files with 217 additions and 9 deletions

View file

@ -550,6 +550,7 @@
</script>
<script type="text/javascript" src="../js/components.js"></script>
<script type="text/javascript" src="../js/reliable_trigger.js" data-cover></script>
<script type="text/javascript" src="test.js"></script>
<script type='text/javascript' src='../js/registration.js' data-cover></script>
@ -624,6 +625,7 @@
<script type="text/javascript" src="storage_test.js"></script>
<script type="text/javascript" src="keychange_listener_test.js"></script>
<script type="text/javascript" src="emoji_util_test.js"></script>
<script type="text/javascript" src="reliable_trigger_test.js"></script>
<script type="text/javascript" src="fixtures.js"></script>
<script type="text/javascript" src="fixtures_test.js"></script>