diff --git a/src/action/multi-sig/store.ts b/src/action/multi-sig/store.ts index 35e18f2..faa9478 100644 --- a/src/action/multi-sig/store.ts +++ b/src/action/multi-sig/store.ts @@ -202,6 +202,7 @@ const storeMultiSigRow = async ( } return row; }; + export { multiSigStoreNewTx, fetchMultiSigRows, diff --git a/src/hooks/useInitConfig.ts b/src/hooks/useInitConfig.ts index ccec323..a99aa70 100644 --- a/src/hooks/useInitConfig.ts +++ b/src/hooks/useInitConfig.ts @@ -34,10 +34,7 @@ const useInitConfig = () => { activeWallet: -1, }; configs.forEach((item) => { - if ( - item.key === ConfigType.DisplayMode && - item.value === 'simple' - ) { + if (item.key === ConfigType.DisplayMode && item.value === 'simple') { config.display = 'simple'; } else if (item.key === ConfigType.Currency) { config.currency = item.value; diff --git a/src/pages/wallet-page/multi-sig/MultiSigCommunication.tsx b/src/pages/wallet-page/multi-sig/MultiSigCommunication.tsx index 355b369..b12fbd9 100644 --- a/src/pages/wallet-page/multi-sig/MultiSigCommunication.tsx +++ b/src/pages/wallet-page/multi-sig/MultiSigCommunication.tsx @@ -2,6 +2,7 @@ import React, { useContext, useEffect, useState } from 'react'; import { useSelector } from 'react-redux'; import { fetchMultiSigBriefRow, + fetchMultiSigRows, notAvailableAddresses, storeMultiSigRow, } from '@/action/multi-sig/store'; @@ -65,12 +66,16 @@ const MultiSigCommunication = (props: MultiSigCommunicationPropsType) => { boxes, ); if (invalidAddresses.length === 0) { + const oldRow = await fetchMultiSigRows(props.wallet, [ + tx.unsigned_tx().id().to_str(), + ]); + const secrets = oldRow.length > 0 ? oldRow[0].secrets : [[]]; const row = await storeMultiSigRow( props.wallet, tx, boxes, data.commitments, - [[]], + secrets, data.signed || [], data.simulated || [], Date.now(),