Skip to content

Commit

Permalink
FIX: Performing actions on a particular reviewable was displaying an …
Browse files Browse the repository at this point in the history
…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.
  • Loading branch information
eviltrout committed Jun 12, 2019
1 parent c5dec04 commit 13b979c
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -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));
Expand Down

0 comments on commit 13b979c

Please sign in to comment.