mirror of
https://github.com/TryGhost/Ghost.git
synced 2024-12-26 12:21:36 +03:00
Fixed member deletion UI getting stuck in certain cases
no issues refs https://github.com/emberjs/ember.js/issues/5566#issuecomment-429389165 Member deletion UI gets stuck in UI when deleted via these steps: View member list, filtered by label. Click on a member, delete them. Admin transitions back to previous screen before action is completed — deletion completes successfully but deletion UI hangs. This happens due to a niche ember bug which causes transitions to abort when transitioning to a route with query params having `refreshModel:true`. The fix is simple one liner with return being separated from the route transition statement.
This commit is contained in:
parent
107ed0e1f3
commit
3cd092f5fe
@ -78,7 +78,8 @@ export default class MemberController extends Controller {
|
|||||||
};
|
};
|
||||||
return this.member.destroyRecord(options).then(() => {
|
return this.member.destroyRecord(options).then(() => {
|
||||||
this.members.refreshData();
|
this.members.refreshData();
|
||||||
return this.transitionToRoute('members');
|
this.transitionToRoute('members');
|
||||||
|
return;
|
||||||
}, (error) => {
|
}, (error) => {
|
||||||
return this.notifications.showAPIError(error, {key: 'member.delete'});
|
return this.notifications.showAPIError(error, {key: 'member.delete'});
|
||||||
});
|
});
|
||||||
|
Loading…
Reference in New Issue
Block a user