1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-19 01:33:33 +00:00

Pass vault state (locked/unlocked) to notificationBar

This commit is contained in:
Daniel James Smith
2021-09-30 16:09:42 +02:00
parent 210e0801ff
commit 686c7fbfff
3 changed files with 10 additions and 2 deletions

View File

@@ -676,13 +676,20 @@ export default class MainBackground {
if (this.notificationQueue[i].tabId !== tab.id || this.notificationQueue[i].domain !== tabDomain) {
continue;
}
if (this.notificationQueue[i].type === 'addLogin') {
BrowserApi.tabSendMessageData(tab, 'openNotificationBar', {
type: 'add',
typeData: {
isVaultLocked: this.notificationQueue[i].wasVaultLocked,
},
});
} else if (this.notificationQueue[i].type === 'changePassword') {
BrowserApi.tabSendMessageData(tab, 'openNotificationBar', {
type: 'change',
typeData: {
isVaultLocked: this.notificationQueue[i].wasVaultLocked,
},
});
}
break;