Deduplicate TxsResponse

This commit is contained in:
Simon Warta 2020-06-19 13:10:00 +02:00
parent b88646392c
commit 619ecbf014
5 changed files with 6 additions and 38 deletions

View File

@ -1,7 +1,7 @@
import * as logs from "./logs";
export { logs };
export { RestClient, TxsResponse } from "./restclient";
export { RestClient } from "./restclient";
export {
Account,
Block,

View File

@ -15,6 +15,7 @@ import {
StdFee,
StdSignature,
StdTx,
TxsResponse,
} from "@cosmjs/sdk38";
import { assert, sleep } from "@cosmjs/utils";
import { ReadonlyDate } from "readonly-date";
@ -28,7 +29,7 @@ import {
MsgInstantiateContract,
MsgStoreCode,
} from "./msgs";
import { RestClient, TxsResponse } from "./restclient";
import { RestClient } from "./restclient";
import { SigningCosmWasmClient } from "./signingcosmwasmclient";
import cosmoshub from "./testdata/cosmoshub.json";
import {

View File

@ -1,5 +1,5 @@
import { fromBase64, fromUtf8, toHex, toUtf8 } from "@cosmjs/encoding";
import { BroadcastMode, CosmosSdkTx, RestClient as BaseRestClient } from "@cosmjs/sdk38";
import { BroadcastMode, RestClient as BaseRestClient } from "@cosmjs/sdk38";
import { JsonObject, Model, parseWasmData, WasmData } from "./types";
@ -17,23 +17,6 @@ interface WasmError {
readonly error: string;
}
export interface TxsResponse {
readonly height: string;
readonly txhash: string;
/** 🤷‍♂️ */
readonly codespace?: string;
/** Falsy when transaction execution succeeded. Contains error code on error. */
readonly code?: number;
readonly raw_log: string;
readonly logs?: object;
readonly tx: CosmosSdkTx;
/** The gas limit as set by the user */
readonly gas_wanted?: string;
/** The gas used by the execution */
readonly gas_used?: string;
readonly timestamp: string;
}
export interface CodeInfo {
readonly id: number;
/** Bech32 account address */

View File

@ -1,6 +1,6 @@
import * as logs from "./logs";
export { logs };
export { RestClient, TxsResponse } from "./restclient";
export { RestClient } from "./restclient";
export {
Account,
Block,

View File

@ -1,21 +1,5 @@
import { BroadcastMode, CosmosSdkTx, RestClient as BaseRestClient } from "@cosmjs/sdk38";
import { BroadcastMode, RestClient as BaseRestClient } from "@cosmjs/sdk38";
import { JsonObject, Model } from "./types";
export interface TxsResponse {
readonly height: string;
readonly txhash: string;
/** 🤷‍♂️ */
readonly codespace?: string;
/** Falsy when transaction execution succeeded. Contains error code on error. */
readonly code?: number;
readonly raw_log: string;
readonly logs?: object;
readonly tx: CosmosSdkTx;
/** The gas limit as set by the user */
readonly gas_wanted?: string;
/** The gas used by the execution */
readonly gas_used?: string;
readonly timestamp: string;
}
export interface CodeInfo {
readonly id: number;
/** Bech32 account address */