Skip to content

Commit

Permalink
mod - transactions should not have constant empty withdrawals.
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthew Eric Bassett committed Aug 3, 2020
1 parent cc44ca6 commit 7515e28
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/services/transactionHistory.ts
Expand Up @@ -172,7 +172,7 @@ export const askTransactionHistory = async (
, index: obj.f4
, txHash: obj.f3}));
const outputs = row.outAddrValPairs.map( ( obj:any ): TransOutputFrag => ({ address: obj.f1, amount: obj.f2.toString() }));
const withdrawals : TransOutputFrag[] = row.withdrawals ? row.withdrawals.map( ( obj:any ): TransOutputFrag => ({ address: obj.f1, amount: obj.f2.toString() })) : null;
const withdrawals : TransOutputFrag[] = row.withdrawals ? row.withdrawals.map( ( obj:any ): TransOutputFrag => ({ address: obj.f1, amount: obj.f2.toString() })) : [];
const blockFrag : BlockFrag = { number: row.blockNumber
, hash: row.blockHash.toString("hex")
, epochNo: row.blockEpochNo
Expand All @@ -187,7 +187,7 @@ export const askTransactionHistory = async (
, ttl: MAX_INT
, blockEra: row.blockEra === "byron" ? BlockEra.Byron : BlockEra.Shelley
, txIndex: row.txIndex
, withdrawals: []
, withdrawals: withdrawals
};
});

Expand Down

0 comments on commit 7515e28

Please sign in to comment.