Awaiting doesn't work, it throws the error if another request is already executing. For example, when you open the dms view and it's simultaneously trying to encrypt lots of messages in different components.

Reply to this note

Please Login to reply.

Discussion

Decrypt, I mean. But it's working now in Iris because I coded my own processing queue for it.

I also had this problem, i had to implement barrier to allow only 1 call at a time, but i believe it might be a limit for `postMessage` ?

I mean like this:

await window.nostr.nip04.decrypt(...);

await window.nostr.nip04.decrypt(...);

this should work, doesn't it? but I guess you do this in a component that don't know of the other calls?

I am wondering what's the best practice here. because the user might be prompted.