diff options
author | Alexander Tseung <alextsg@users.noreply.github.com> | 2018-10-16 06:00:47 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-10-16 06:00:47 +0800 |
commit | c821a8354c8eba05885ca219f39aedafbd4f8052 (patch) | |
tree | 880b60c46a0c3f0873a58f16077623211140ac0e /ui/app/components/transaction-activity-log/transaction-activity-log.util.js | |
parent | 61dec4ea464607d32a5727bdf343a7d8a9af66fc (diff) | |
download | tangerine-wallet-browser-c821a8354c8eba05885ca219f39aedafbd4f8052.tar tangerine-wallet-browser-c821a8354c8eba05885ca219f39aedafbd4f8052.tar.gz tangerine-wallet-browser-c821a8354c8eba05885ca219f39aedafbd4f8052.tar.bz2 tangerine-wallet-browser-c821a8354c8eba05885ca219f39aedafbd4f8052.tar.lz tangerine-wallet-browser-c821a8354c8eba05885ca219f39aedafbd4f8052.tar.xz tangerine-wallet-browser-c821a8354c8eba05885ca219f39aedafbd4f8052.tar.zst tangerine-wallet-browser-c821a8354c8eba05885ca219f39aedafbd4f8052.zip |
Add txReceipt data to transaction details (#5513)
Diffstat (limited to 'ui/app/components/transaction-activity-log/transaction-activity-log.util.js')
-rw-r--r-- | ui/app/components/transaction-activity-log/transaction-activity-log.util.js | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/ui/app/components/transaction-activity-log/transaction-activity-log.util.js b/ui/app/components/transaction-activity-log/transaction-activity-log.util.js index 32834ff47..97aa9a8f1 100644 --- a/ui/app/components/transaction-activity-log/transaction-activity-log.util.js +++ b/ui/app/components/transaction-activity-log/transaction-activity-log.util.js @@ -46,11 +46,15 @@ export function getActivities (transaction) { if (!Array.isArray(base) && base.status === UNAPPROVED_STATUS && base.txParams) { const { time, txParams: { value } = {} } = base return acc.concat(eventCreator(TRANSACTION_CREATED_EVENT, time, value)) + // An entry in the history may be an array of more sub-entries. } else if (Array.isArray(base)) { const events = [] base.forEach(entry => { - const { op, path, value, timestamp } = entry + const { op, path, value, timestamp: entryTimestamp } = entry + // Not all sub-entries in a history entry have a timestamp. If the sub-entry does not have a + // timestamp, the first sub-entry in a history entry should. + const timestamp = entryTimestamp || base[0] && base[0].timestamp if (path in eventPathsHash && op === REPLACE_OP) { switch (path) { |