Skip to content

Commit 7309349

Browse files
authored
fix bug with time computation that causes losing some seconds (#258)
1 parent 4084c8d commit 7309349

File tree

1 file changed

+1
-1
lines changed
  • services/frontend/react_app/src/pages

1 file changed

+1
-1
lines changed

services/frontend/react_app/src/pages/home.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ export const HomePage = () => {
196196
<HStack divider={<StackDivider/>} spacing='4' justifyContent="center" alignItems="center"
197197
bg="teal.200" p="1rem" maxW={600} borderRadius={4}>
198198
<Countdown
199-
date={new Date(Date.now()).setSeconds(lastRequestedDrive.driverArrival)}
199+
date={new Date(Date.now() + lastRequestedDrive.driverArrival * 1000)}
200200
renderer={(props) => countdownRenderer({
201201
...props,
202202
driverName: lastRequestedDrive.driverDetails.name,

0 commit comments

Comments
 (0)