Skip to content

Commit

Permalink
Made LiveFaults.tsx count the actual count rather than resetting it, …
Browse files Browse the repository at this point in the history
…to accomodate for multiple boards
  • Loading branch information
matthlh committed Nov 24, 2024
1 parent 69031dc commit 6b5a000
Showing 1 changed file with 2 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -89,13 +89,11 @@ const LiveFault: React.FC = () => {

setBoard1((prev) => {
const object = {
timestamp: prev[prev.length - 1].timestamp + count,
timestamp: count,
name: newFaults[key] ? 'fault1' : 'e',
}
return [...prev, object]
})

setCount(0)
}

// ! DEBUGGING: REMOVE
Expand All @@ -122,13 +120,11 @@ const LiveFault: React.FC = () => {

setBoard1((prev) => {
const object = {
timestamp: prev[prev.length - 1].timestamp + count,
timestamp: count,
name: newWarnings[key] ? 'warning1' : 'e',
}
return [...prev, object]
})

setCount(0)
}

// ! DEBUGGING: REMOVE ================
Expand Down

0 comments on commit 6b5a000

Please sign in to comment.