Also, I am wondering about why model.destroyRecord() is used for the new route, but rollbackAttributes() is used for edit. model.rollbackAttributes works fine in both cases, where the section of code in new will look like
deactivate: function(){
var model = this.modelFor('friends/new');
model.rollbackAttributes();
book version: 15-7-20 location: 1795
model.rollback() renamed to rollbackAttributes
release notes on deprecation/rename: http://emberjs.com/blog/2015/06/18/ember-data-1-13-released.html#sts=rollback
Also, I am wondering about why model.destroyRecord() is used for the
new
route, but rollbackAttributes() is used foredit
. model.rollbackAttributes works fine in both cases, where the section of code innew
will look like