diff --git a/ethers/providers/jsonrpc.nim b/ethers/providers/jsonrpc.nim index 5574ea9..256fcc6 100644 --- a/ethers/providers/jsonrpc.nim +++ b/ethers/providers/jsonrpc.nim @@ -158,9 +158,9 @@ method subscribe*(provider: JsonRpcProvider, method unsubscribe*(subscription: JsonRpcSubscription) {.async.} = let provider = subscription.provider + provider.subscriptions.del(subscription.id) let client = await provider.client discard await client.eth_unsubscribe(subscription.id) - provider.subscriptions.del(subscription.id) # Signer