Skip to content

Commit

Permalink
fix nanptps data
Browse files Browse the repository at this point in the history
  • Loading branch information
tombertrand committed Feb 28, 2024
1 parent dd6f7be commit fe49573
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions server/cron/nanotpsStats.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@ const doNanoTpsStats = async () => {

const { send: sends, receive: receives, change: changes } = await res.json();

let send = sends[sends.length - 1];
let receive = receives[receives.length - 1];
let change = changes[changes.length - 1];
let send = sends[0];
let receive = receives[0];
let change = changes[0];

const stats = { send, receive, change };

Expand All @@ -32,3 +32,5 @@ cron.schedule("0 * * * *", async () => {
if (process.env.NODE_ENV === "production") {
doNanoTpsStats();
}

doNanoTpsStats();

0 comments on commit fe49573

Please sign in to comment.