get rid of typescript empty object warning

This commit is contained in:
Sebastian 2022-10-24 10:28:37 -03:00
parent 27f10e6e83
commit 7a80d33414
No known key found for this signature in database
GPG Key ID: BE4FF68352439FC1
2 changed files with 47 additions and 46 deletions

View File

@ -697,7 +697,7 @@ export interface WalletCoreVersion {
exchange: string; exchange: string;
merchant: string; merchant: string;
bank: string; bank: string;
devMode?: boolean; devMode: boolean;
} }
export interface KnownBankAccountsInfo { export interface KnownBankAccountsInfo {

View File

@ -177,6 +177,7 @@ export enum WalletApiOperation {
// group: Initialization // group: Initialization
type EmptyObject = Record<string, never>;
/** /**
* Initialize wallet-core. * Initialize wallet-core.
* *
@ -184,13 +185,13 @@ export enum WalletApiOperation {
*/ */
export type InitWalletOp = { export type InitWalletOp = {
op: WalletApiOperation.InitWallet; op: WalletApiOperation.InitWallet;
request: {}; request: EmptyObject;
response: InitResponse; response: InitResponse;
}; };
export type GetVersionOp = { export type GetVersionOp = {
op: WalletApiOperation.GetVersion; op: WalletApiOperation.GetVersion;
request: {}; request: EmptyObject;
response: WalletCoreVersion; response: WalletCoreVersion;
}; };
@ -201,7 +202,7 @@ export type GetVersionOp = {
*/ */
export type GetBalancesOp = { export type GetBalancesOp = {
op: WalletApiOperation.GetBalances; op: WalletApiOperation.GetBalances;
request: {}; request: EmptyObject;
response: BalancesResponse; response: BalancesResponse;
}; };
@ -224,8 +225,8 @@ export type GetTransactionByIdOp = {
export type RetryPendingNowOp = { export type RetryPendingNowOp = {
op: WalletApiOperation.RetryPendingNow; op: WalletApiOperation.RetryPendingNow;
request: {}; request: EmptyObject;
response: {}; response: EmptyObject;
}; };
/** /**
@ -234,7 +235,7 @@ export type RetryPendingNowOp = {
export type DeleteTransactionOp = { export type DeleteTransactionOp = {
op: WalletApiOperation.DeleteTransaction; op: WalletApiOperation.DeleteTransaction;
request: DeleteTransactionRequest; request: DeleteTransactionRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -243,7 +244,7 @@ export type DeleteTransactionOp = {
export type RetryTransactionOp = { export type RetryTransactionOp = {
op: WalletApiOperation.RetryTransaction; op: WalletApiOperation.RetryTransaction;
request: RetryTransactionRequest; request: RetryTransactionRequest;
response: {}; response: EmptyObject;
}; };
// group: Withdrawals // group: Withdrawals
@ -317,7 +318,7 @@ export type ConfirmPayOp = {
export type AbortPayWithRefundOp = { export type AbortPayWithRefundOp = {
op: WalletApiOperation.AbortFailedPayWithRefund; op: WalletApiOperation.AbortFailedPayWithRefund;
request: AbortPayWithRefundRequest; request: AbortPayWithRefundRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -358,7 +359,7 @@ export type PrepareTipOp = {
export type AcceptTipOp = { export type AcceptTipOp = {
op: WalletApiOperation.AcceptTip; op: WalletApiOperation.AcceptTip;
request: AcceptTipRequest; request: AcceptTipRequest;
response: {}; response: EmptyObject;
}; };
// group: Exchange Management // group: Exchange Management
@ -368,7 +369,7 @@ export type AcceptTipOp = {
*/ */
export type ListExchangesOp = { export type ListExchangesOp = {
op: WalletApiOperation.ListExchanges; op: WalletApiOperation.ListExchanges;
request: {}; request: EmptyObject;
response: ExchangesListResponse; response: ExchangesListResponse;
}; };
@ -378,7 +379,7 @@ export type ListExchangesOp = {
export type AddExchangeOp = { export type AddExchangeOp = {
op: WalletApiOperation.AddExchange; op: WalletApiOperation.AddExchange;
request: AddExchangeRequest; request: AddExchangeRequest;
response: {}; response: EmptyObject;
}; };
export type ListKnownBankAccountsOp = { export type ListKnownBankAccountsOp = {
@ -390,13 +391,13 @@ export type ListKnownBankAccountsOp = {
export type AddKnownBankAccountsOp = { export type AddKnownBankAccountsOp = {
op: WalletApiOperation.AddKnownBankAccounts; op: WalletApiOperation.AddKnownBankAccounts;
request: AddKnownBankAccountsRequest; request: AddKnownBankAccountsRequest;
response: {}; response: EmptyObject;
}; };
export type ForgetKnownBankAccountsOp = { export type ForgetKnownBankAccountsOp = {
op: WalletApiOperation.ForgetKnownBankAccounts; op: WalletApiOperation.ForgetKnownBankAccounts;
request: ForgetKnownBankAccountsRequest; request: ForgetKnownBankAccountsRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -405,7 +406,7 @@ export type ForgetKnownBankAccountsOp = {
export type SetExchangeTosAcceptedOp = { export type SetExchangeTosAcceptedOp = {
op: WalletApiOperation.SetExchangeTosAccepted; op: WalletApiOperation.SetExchangeTosAccepted;
request: AcceptExchangeTosRequest; request: AcceptExchangeTosRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -431,7 +432,7 @@ export type GetExchangeDetailedInfoOp = {
*/ */
export type ListCurrenciesOp = { export type ListCurrenciesOp = {
op: WalletApiOperation.ListCurrencies; op: WalletApiOperation.ListCurrencies;
request: {}; request: EmptyObject;
response: WalletCurrencyInfo; response: WalletCurrencyInfo;
}; };
@ -477,7 +478,7 @@ export type PrepareDepositOp = {
*/ */
export type ExportBackupRecoveryOp = { export type ExportBackupRecoveryOp = {
op: WalletApiOperation.ExportBackupRecovery; op: WalletApiOperation.ExportBackupRecovery;
request: {}; request: EmptyObject;
response: BackupRecovery; response: BackupRecovery;
}; };
@ -487,7 +488,7 @@ export type ExportBackupRecoveryOp = {
export type ImportBackupRecoveryOp = { export type ImportBackupRecoveryOp = {
op: WalletApiOperation.ImportBackupRecovery; op: WalletApiOperation.ImportBackupRecovery;
request: RecoveryLoadRequest; request: RecoveryLoadRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -495,14 +496,14 @@ export type ImportBackupRecoveryOp = {
*/ */
export type RunBackupCycleOp = { export type RunBackupCycleOp = {
op: WalletApiOperation.RunBackupCycle; op: WalletApiOperation.RunBackupCycle;
request: {}; request: EmptyObject;
response: {}; response: EmptyObject;
}; };
export type ExportBackupOp = { export type ExportBackupOp = {
op: WalletApiOperation.ExportBackup; op: WalletApiOperation.ExportBackup;
request: {}; request: EmptyObject;
response: {}; response: EmptyObject;
}; };
/** /**
@ -511,13 +512,13 @@ export type ExportBackupOp = {
export type AddBackupProviderOp = { export type AddBackupProviderOp = {
op: WalletApiOperation.AddBackupProvider; op: WalletApiOperation.AddBackupProvider;
request: AddBackupProviderRequest; request: AddBackupProviderRequest;
response: {}; response: EmptyObject;
}; };
export type RemoveBackupProviderOp = { export type RemoveBackupProviderOp = {
op: WalletApiOperation.RemoveBackupProvider; op: WalletApiOperation.RemoveBackupProvider;
request: RemoveBackupProviderRequest; request: RemoveBackupProviderRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -525,7 +526,7 @@ export type RemoveBackupProviderOp = {
*/ */
export type GetBackupInfoOp = { export type GetBackupInfoOp = {
op: WalletApiOperation.GetBackupInfo; op: WalletApiOperation.GetBackupInfo;
request: {}; request: EmptyObject;
response: BackupInfo; response: BackupInfo;
}; };
@ -537,7 +538,7 @@ export type GetBackupInfoOp = {
export type SetWalletDeviceIdOp = { export type SetWalletDeviceIdOp = {
op: WalletApiOperation.SetWalletDeviceId; op: WalletApiOperation.SetWalletDeviceId;
request: SetWalletDeviceIdRequest; request: SetWalletDeviceIdRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -545,7 +546,7 @@ export type SetWalletDeviceIdOp = {
*/ */
export type ExportBackupPlainOp = { export type ExportBackupPlainOp = {
op: WalletApiOperation.ExportBackupPlain; op: WalletApiOperation.ExportBackupPlain;
request: {}; request: EmptyObject;
response: WalletBackupContentV1; response: WalletBackupContentV1;
}; };
@ -575,7 +576,7 @@ export type CheckPeerPushPaymentOp = {
export type AcceptPeerPushPaymentOp = { export type AcceptPeerPushPaymentOp = {
op: WalletApiOperation.AcceptPeerPushPayment; op: WalletApiOperation.AcceptPeerPushPayment;
request: AcceptPeerPushPaymentRequest; request: AcceptPeerPushPaymentRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -602,7 +603,7 @@ export type CheckPeerPullPaymentOp = {
export type AcceptPeerPullPaymentOp = { export type AcceptPeerPullPaymentOp = {
op: WalletApiOperation.AcceptPeerPullPayment; op: WalletApiOperation.AcceptPeerPullPayment;
request: AcceptPeerPullPaymentRequest; request: AcceptPeerPullPaymentRequest;
response: {}; response: EmptyObject;
}; };
// group: Database Management // group: Database Management
@ -612,7 +613,7 @@ export type AcceptPeerPullPaymentOp = {
*/ */
export type ExportDbOp = { export type ExportDbOp = {
op: WalletApiOperation.ExportDb; op: WalletApiOperation.ExportDb;
request: {}; request: EmptyObject;
response: any; response: any;
}; };
@ -627,8 +628,8 @@ export type ImportDbOp = {
*/ */
export type ClearDbOp = { export type ClearDbOp = {
op: WalletApiOperation.ClearDb; op: WalletApiOperation.ClearDb;
request: {}; request: EmptyObject;
response: {}; response: EmptyObject;
}; };
/** /**
@ -636,8 +637,8 @@ export type ClearDbOp = {
*/ */
export type RecycleOp = { export type RecycleOp = {
op: WalletApiOperation.Recycle; op: WalletApiOperation.Recycle;
request: {}; request: EmptyObject;
response: {}; response: EmptyObject;
}; };
// group: Testing and Debugging // group: Testing and Debugging
@ -651,13 +652,13 @@ export type RecycleOp = {
export type ApplyDevExperimentOp = { export type ApplyDevExperimentOp = {
op: WalletApiOperation.ApplyDevExperiment; op: WalletApiOperation.ApplyDevExperiment;
request: ApplyDevExperimentRequest; request: ApplyDevExperimentRequest;
response: {}; response: EmptyObject;
}; };
export type SetDevModeOp = { export type SetDevModeOp = {
op: WalletApiOperation.SetDevMode; op: WalletApiOperation.SetDevMode;
request: SetDevModeRequest; request: SetDevModeRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -667,7 +668,7 @@ export type SetDevModeOp = {
export type RunIntegrationTestOp = { export type RunIntegrationTestOp = {
op: WalletApiOperation.RunIntegrationTest; op: WalletApiOperation.RunIntegrationTest;
request: IntegrationTestArgs; request: IntegrationTestArgs;
response: {}; response: EmptyObject;
}; };
/** /**
@ -675,7 +676,7 @@ export type RunIntegrationTestOp = {
*/ */
export type TestCryptoOp = { export type TestCryptoOp = {
op: WalletApiOperation.TestCrypto; op: WalletApiOperation.TestCrypto;
request: {}; request: EmptyObject;
response: any; response: any;
}; };
@ -686,7 +687,7 @@ export type TestCryptoOp = {
export type WithdrawTestBalanceOp = { export type WithdrawTestBalanceOp = {
op: WalletApiOperation.WithdrawTestBalance; op: WalletApiOperation.WithdrawTestBalance;
request: WithdrawTestBalanceRequest; request: WithdrawTestBalanceRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -694,8 +695,8 @@ export type WithdrawTestBalanceOp = {
*/ */
export type WithdrawTestkudosOp = { export type WithdrawTestkudosOp = {
op: WalletApiOperation.WithdrawTestkudos; op: WalletApiOperation.WithdrawTestkudos;
request: {}; request: EmptyObject;
response: {}; response: EmptyObject;
}; };
/** /**
@ -716,7 +717,7 @@ export type TestPayOp = {
export type WithdrawFakebankOp = { export type WithdrawFakebankOp = {
op: WalletApiOperation.WithdrawFakebank; op: WalletApiOperation.WithdrawFakebank;
request: WithdrawFakebankRequest; request: WithdrawFakebankRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -724,7 +725,7 @@ export type WithdrawFakebankOp = {
*/ */
export type GetPendingTasksOp = { export type GetPendingTasksOp = {
op: WalletApiOperation.GetPendingOperations; op: WalletApiOperation.GetPendingOperations;
request: {}; request: EmptyObject;
response: PendingTasksResponse; response: PendingTasksResponse;
}; };
@ -733,7 +734,7 @@ export type GetPendingTasksOp = {
*/ */
export type DumpCoinsOp = { export type DumpCoinsOp = {
op: WalletApiOperation.DumpCoins; op: WalletApiOperation.DumpCoins;
request: {}; request: EmptyObject;
response: CoinDumpJson; response: CoinDumpJson;
}; };
@ -744,7 +745,7 @@ export type DumpCoinsOp = {
export type SetCoinSuspendedOp = { export type SetCoinSuspendedOp = {
op: WalletApiOperation.SetCoinSuspended; op: WalletApiOperation.SetCoinSuspended;
request: SetCoinSuspendedRequest; request: SetCoinSuspendedRequest;
response: {}; response: EmptyObject;
}; };
/** /**
@ -754,7 +755,7 @@ export type SetCoinSuspendedOp = {
export type ForceRefreshOp = { export type ForceRefreshOp = {
op: WalletApiOperation.ForceRefresh; op: WalletApiOperation.ForceRefresh;
request: ForceRefreshRequest; request: ForceRefreshRequest;
response: {}; response: EmptyObject;
}; };
export type WalletOperations = { export type WalletOperations = {