@wagmi/core
Advanced tools
Comparing version 2.13.7 to 2.13.8
@@ -364,6 +364,11 @@ import { ResourceUnavailableRpcError, SwitchChainError, UserRejectedRequestError, getAddress, numberToHex, withRetry, withTimeout, } from 'viem'; | ||
}), | ||
new Promise((resolve) => config.emitter.once('change', ({ chainId: currentChainId }) => { | ||
if (currentChainId === chainId) | ||
resolve(); | ||
})), | ||
new Promise((resolve) => { | ||
const listener = ((data) => { | ||
if ('chainId' in data && data.chainId === chainId) { | ||
config.emitter.off('change', listener); | ||
resolve(); | ||
} | ||
}); | ||
config.emitter.on('change', listener); | ||
}), | ||
]); | ||
@@ -370,0 +375,0 @@ return chain; |
@@ -1,2 +0,2 @@ | ||
export const version = '2.13.7'; | ||
export const version = '2.13.8'; | ||
//# sourceMappingURL=version.js.map |
@@ -1,2 +0,2 @@ | ||
export declare const version = "2.13.7"; | ||
export declare const version = "2.13.8"; | ||
//# sourceMappingURL=version.d.ts.map |
{ | ||
"name": "@wagmi/core", | ||
"description": "VanillaJS library for Ethereum", | ||
"version": "2.13.7", | ||
"version": "2.13.8", | ||
"license": "MIT", | ||
@@ -6,0 +6,0 @@ "repository": { |
@@ -431,7 +431,11 @@ import { | ||
}), | ||
new Promise<void>((resolve) => | ||
config.emitter.once('change', ({ chainId: currentChainId }) => { | ||
if (currentChainId === chainId) resolve() | ||
}), | ||
), | ||
new Promise<void>((resolve) => { | ||
const listener = ((data) => { | ||
if ('chainId' in data && data.chainId === chainId) { | ||
config.emitter.off('change', listener) | ||
resolve() | ||
} | ||
}) satisfies Parameters<typeof config.emitter.on>[1] | ||
config.emitter.on('change', listener) | ||
}), | ||
]) | ||
@@ -438,0 +442,0 @@ return chain |
@@ -1,1 +0,1 @@ | ||
export const version = '2.13.7' | ||
export const version = '2.13.8' |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1776322
19148