diff --git a/packages/bcp/src/cosmwasmconnection.ts b/packages/bcp/src/cosmwasmconnection.ts index 4bacadb1..afd6ea70 100644 --- a/packages/bcp/src/cosmwasmconnection.ts +++ b/packages/bcp/src/cosmwasmconnection.ts @@ -3,7 +3,6 @@ import { CosmosAddressBech32Prefix, CosmWasmClient, findSequenceForSignedTx, - RestClient, TxsResponse, types, } from "@cosmwasm/sdk"; @@ -74,10 +73,9 @@ export class CosmWasmConnection implements BlockchainConnection { addressPrefix: CosmosAddressBech32Prefix, tokens: TokenConfiguration, ): Promise { - const restClient = new RestClient(url); const cosmWasmClient = CosmWasmClient.makeReadOnly(url); const chainData = await this.initialize(cosmWasmClient); - return new CosmWasmConnection(restClient, cosmWasmClient, chainData, addressPrefix, tokens); + return new CosmWasmConnection(cosmWasmClient, chainData, addressPrefix, tokens); } private static async initialize(cosmWasmClient: CosmWasmClient): Promise { @@ -88,8 +86,6 @@ export class CosmWasmConnection implements BlockchainConnection { public readonly chainId: ChainId; public readonly codec: TxCodec; - /** @deprecated everything we use from RestClient should be available in CosmWasmClient */ - private readonly restClient: RestClient; private readonly cosmWasmClient: CosmWasmClient; private readonly addressPrefix: CosmosAddressBech32Prefix; private readonly bankTokens: readonly BankToken[]; @@ -100,14 +96,11 @@ export class CosmWasmConnection implements BlockchainConnection { private readonly supportedTokens: readonly Token[]; private constructor( - restClient: RestClient, cosmWasmClient: CosmWasmClient, chainId: ChainId, addressPrefix: CosmosAddressBech32Prefix, tokens: TokenConfiguration, ) { - // tslint:disable-next-line: deprecation - this.restClient = restClient; this.cosmWasmClient = cosmWasmClient; this.chainId = chainId; this.codec = new CosmWasmCodec(addressPrefix, tokens.bankTokens, tokens.erc20Tokens); diff --git a/packages/bcp/types/cosmwasmconnection.d.ts b/packages/bcp/types/cosmwasmconnection.d.ts index 0274f4c8..dff506c5 100644 --- a/packages/bcp/types/cosmwasmconnection.d.ts +++ b/packages/bcp/types/cosmwasmconnection.d.ts @@ -47,8 +47,6 @@ export declare class CosmWasmConnection implements BlockchainConnection { private static initialize; readonly chainId: ChainId; readonly codec: TxCodec; - /** @deprecated everything we use from RestClient should be available in CosmWasmClient */ - private readonly restClient; private readonly cosmWasmClient; private readonly addressPrefix; private readonly bankTokens;