From 073967c1bf7f03a920df9322438ff480fb4242a2 Mon Sep 17 00:00:00 2001 From: curtelsasser Date: Fri, 28 May 2021 13:01:02 -0400 Subject: [PATCH] - very perplexed by tsc constraint observations --- app/src/redux/robot/reducer/session.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/src/redux/robot/reducer/session.js b/app/src/redux/robot/reducer/session.js index 73719a01500..b0eba46beff 100644 --- a/app/src/redux/robot/reducer/session.js +++ b/app/src/redux/robot/reducer/session.js @@ -318,7 +318,8 @@ function handlePauseResponse(state: SessionState, action: any): SessionState { } function handleResume(state: SessionState, action: any): SessionState { - const pausedDuration = state.pausedTime ? Date.now() - state.pausedTime : 0 + const pausedDuration = + state.pausedTime === null ? 0 : Date.now() - Number(state.pausedTime) return { ...state, pausedDuration: state.pausedDuration + pausedDuration,