@sats-connect/core 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.mjs +7 -0
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -553,6 +553,13 @@ var addListener = (event, cb, providerId) => {
|
|
|
553
553
|
if (!provider) {
|
|
554
554
|
throw new Error("no wallet provider was found");
|
|
555
555
|
}
|
|
556
|
+
if (!provider.addListener) {
|
|
557
|
+
console.error(
|
|
558
|
+
`The wallet provider you are using does not support the addListener method. Please update your wallet provider.`
|
|
559
|
+
);
|
|
560
|
+
return () => {
|
|
561
|
+
};
|
|
562
|
+
}
|
|
556
563
|
return provider.addListener(event, cb);
|
|
557
564
|
};
|
|
558
565
|
|