mirror of
https://github.com/lil-org/wallet.git
synced 2025-01-07 13:46:25 +03:00
Deliver responses to multiple inpage providers on switch account action
This commit is contained in:
parent
e4ad237053
commit
dca0e5bc48
File diff suppressed because one or more lines are too long
@ -71,7 +71,12 @@ function deliverResponseToSpecificProvider(id, response, provider) {
|
||||
window.near.processTokenaryResponse(id, response);
|
||||
break;
|
||||
case "multiple":
|
||||
// TODO: go through all bodies, enrich em with name and id, pass to each envolved provider
|
||||
response.bodies.forEach((body) => {
|
||||
body.id = id;
|
||||
body.name = response.name;
|
||||
deliverResponseToSpecificProvider(id, body, body.provider);
|
||||
});
|
||||
// TODO: disconnect response.providersToDisconnect
|
||||
break;
|
||||
default:
|
||||
// pass unknown provider message to all providers
|
||||
|
Loading…
Reference in New Issue
Block a user