mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-07 09:31:31 +01:00
process bitwardenFrameId on safari
This commit is contained in:
parent
7d2c4cbd9a
commit
5c47b33967
@ -208,7 +208,14 @@ export class BrowserApi {
|
||||
callback(msg, sender, response);
|
||||
});
|
||||
} else if (BrowserApi.isSafariApi) {
|
||||
SafariApp.addMessageListener(name, callback);
|
||||
SafariApp.addMessageListener(name, (message: any, sender: any, response: any) => {
|
||||
if (message.bitwardenFrameId != null) {
|
||||
if (sender != null && typeof (sender) === 'object' && sender.frameId == null) {
|
||||
sender.frameId = message.bitwardenFrameId;
|
||||
}
|
||||
}
|
||||
callback(message, sender, response);
|
||||
});
|
||||
/*
|
||||
safari.application.addEventListener('message', async (msgEvent: any) => {
|
||||
callback(msgEvent.message, {
|
||||
|
Loading…
Reference in New Issue
Block a user