Reset context menu when assignment changes. Fixes #589

This commit is contained in:
Jonathan Kingston 2017-06-15 13:39:22 +01:00
parent bfc6f68978
commit 68c21624e2

View file

@ -163,7 +163,6 @@ const assignManager = {
remove = true; remove = true;
} }
await this._setOrRemoveAssignment(tab.id, info.pageUrl, userContextId, remove); await this._setOrRemoveAssignment(tab.id, info.pageUrl, userContextId, remove);
this.calculateContextMenu(tab);
} }
}, },
@ -216,6 +215,8 @@ const assignManager = {
event: `${actionName}-container-assignment`, event: `${actionName}-container-assignment`,
userContextId: userContextId, userContextId: userContextId,
}); });
const tab = await browser.tabs.get(tabId);
this.calculateContextMenu(tab);
}, },
async _getAssignment(tab) { async _getAssignment(tab) {