File tree Expand file tree Collapse file tree 3 files changed +4
-8
lines changed Expand file tree Collapse file tree 3 files changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -35,12 +35,8 @@ export async function fetchMetrics (
3535
3636 const res : MetricsResponse = await wfetch ( url , { signal } ) . then ( r => r . json ( ) )
3737
38- res . earnings . forEach ( e => {
39- e . earningsDate = new Date ( e . earningsDate )
40- } )
41- res . metrics . forEach ( m => {
42- m . startTime = new Date ( m . startTime )
43- } )
38+ res . earnings . forEach ( e => { e . timestamp = new Date ( e . timestamp ) } )
39+ res . metrics . forEach ( m => { m . startTime = new Date ( m . startTime ) } )
4440
4541 return res
4642}
Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ export interface Metric {
1010}
1111
1212export interface Earning {
13- earningsDate : Date
13+ timestamp : Date
1414 filAmount : number
1515}
1616
Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ export default function EarningsChart (props: EarningsChartProps) {
3434 }
3535
3636 const data = {
37- labels : earnings . map ( e => e . earningsDate ) ,
37+ labels : earnings . map ( e => e . timestamp ) ,
3838 datasets : [
3939 {
4040 data : earnings . map ( e => e . filAmount ) ,
You can’t perform that action at this time.
0 commit comments