From ad01aa9d6e0a2aab64e408c6bc4843d9d460459b Mon Sep 17 00:00:00 2001 From: Keith Ingram Date: Mon, 6 Jun 2022 16:24:37 +0100 Subject: [PATCH 1/2] Override DispatchError type error field --- src/api/connect.ts | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/api/connect.ts b/src/api/connect.ts index dbb9a46d..1161e9bc 100644 --- a/src/api/connect.ts +++ b/src/api/connect.ts @@ -12,7 +12,15 @@ export const connect = (endpoint: string, dispatch: React.Dispatch) = dispatch({ type: 'CONNECT_INIT' }); const provider = new WsProvider(endpoint); - const _api = new ApiPromise({ provider }); + const _api = new ApiPromise({ + provider, + types: { + DispatchErrorModule: { + index: 'u8', + error: '[u8; 4]', + }, + }, + }); // Set listeners for disconnection and reconnection event. _api.on('connected', async () => { From f007be232d1f1684d9b8779e8f42200209f5e591 Mon Sep 17 00:00:00 2001 From: Keith Ingram Date: Mon, 6 Jun 2022 16:39:40 +0100 Subject: [PATCH 2/2] Fix cypress issue --- src/ui/components/Transactions.tsx | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/ui/components/Transactions.tsx b/src/ui/components/Transactions.tsx index f35586d6..71d2b158 100644 --- a/src/ui/components/Transactions.tsx +++ b/src/ui/components/Transactions.tsx @@ -52,11 +52,7 @@ export function Transactions({ ); })} - dismiss(parseInt(id))} - /> + dismiss(parseInt(id))} /> )}