FIX: Performing actions on a particular reviewable was displaying an error
It was expecting a method to remove the reviewable from the current list, only we were not displaying a list. Instead, we refresh the reviewable model with the latest result.
This commit is contained in:
parent
c5dec04970
commit
13b979cb71
|
@ -92,7 +92,11 @@ export default Ember.Component.extend({
|
|||
this.currentUser.set("reviewable_count", result.reviewable_count);
|
||||
}
|
||||
|
||||
this.attrs.remove(performResult.remove_reviewable_ids);
|
||||
if (this.attrs.remove) {
|
||||
this.attrs.remove(performResult.remove_reviewable_ids);
|
||||
} else {
|
||||
return this.store.find("reviewable", reviewable.id);
|
||||
}
|
||||
})
|
||||
.catch(popupAjaxError)
|
||||
.finally(() => this.set("updating", false));
|
||||
|
|
Loading…
Reference in New Issue