• Robert Knight's avatar
    Fix canceling edits reverting to the first-loaded version of an annotation · 3d9d84ff
    Robert Knight authored
    When updating an annotation, the update is currently applied
    to a copy of the domain model. AIUI the rationale for this is to ensure
    that 'domainModel' always reflects what is actually stored on the
    server, so it should not be updated until after the update is
    successfully committed.
    
    However, after the update is successfully commited, the view was
    updated with the updated domain model, but the local domain model
    instance was never replaced. Therefore when reverting changes,
    the card reverted to the first-loaded text for the annotation
    instead of the last-saved version.
    
    This commit fixes the problem by replacing the domain model
    reference whenever an annotation update is received.
    
    Fixes #2875
    3d9d84ff
Name
Last commit
Last update
..
annotation-test.js Loading commit data...
excerpt-test.js Loading commit data...
form-input-test.coffee Loading commit data...
form-validate-test.coffee Loading commit data...
group-list-test.js Loading commit data...
publish-annotation-btn-test.js Loading commit data...
search-status-bar-test.js Loading commit data...
share-dialog-test.coffee Loading commit data...
sidebar-tutorial-test.js Loading commit data...
simple-search-test.coffee Loading commit data...
sort-dropdown-test.js Loading commit data...
spinner-test.js Loading commit data...
status-button-test.coffee Loading commit data...
thread-test.coffee Loading commit data...
util.js Loading commit data...
window-scroll-test.js Loading commit data...