aboutsummaryrefslogtreecommitdiff
path: root/src/webex/pages/popup.tsx
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2019-11-21 23:09:43 +0100
committerFlorian Dold <florian.dold@gmail.com>2019-11-21 23:09:43 +0100
commitc6233094306cd264f8faa2041388dff01ff8cf01 (patch)
treef3ee839a4254c528058887c6517a76bec8919b15 /src/webex/pages/popup.tsx
parente8f362ccfea683fe16ce68b956f068ffa0b001b1 (diff)
downloadwallet-core-c6233094306cd264f8faa2041388dff01ff8cf01.tar.xz
WIP: simplification and error handling
Diffstat (limited to 'src/webex/pages/popup.tsx')
-rw-r--r--src/webex/pages/popup.tsx8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/webex/pages/popup.tsx b/src/webex/pages/popup.tsx
index 205945471..78b7374b3 100644
--- a/src/webex/pages/popup.tsx
+++ b/src/webex/pages/popup.tsx
@@ -30,7 +30,7 @@ import { AmountJson } from "../../amounts";
import * as Amounts from "../../amounts";
import {
- HistoryRecord,
+ HistoryEvent,
WalletBalance,
WalletBalanceEntry,
} from "../../walletTypes";
@@ -327,7 +327,7 @@ class WalletBalanceView extends React.Component<any, any> {
}
}
-function formatHistoryItem(historyItem: HistoryRecord) {
+function formatHistoryItem(historyItem: HistoryEvent) {
const d = historyItem.detail;
console.log("hist item", historyItem);
switch (historyItem.type) {
@@ -459,7 +459,7 @@ class WalletHistory extends React.Component<any, any> {
render(): JSX.Element {
console.log("rendering history");
- const history: HistoryRecord[] = this.myHistory;
+ const history: HistoryEvent[] = this.myHistory;
if (this.gotError) {
return i18n.str`Error: could not retrieve event history`;
}
@@ -474,7 +474,7 @@ class WalletHistory extends React.Component<any, any> {
const item = (
<div className="historyItem">
<div className="historyDate">
- {new Date(record.timestamp).toString()}
+ {new Date(record.timestamp.t_ms).toString()}
</div>
{formatHistoryItem(record)}
</div>