From b380f64457e9b6ad7a46313a2e4a949d6a464373 Mon Sep 17 00:00:00 2001 From: Stian Aune Date: Thu, 7 Nov 2019 21:36:51 +0100 Subject: [PATCH] Mat og min. --- contentScript.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/contentScript.js b/contentScript.js index 7036989..1fdeb3b 100644 --- a/contentScript.js +++ b/contentScript.js @@ -390,12 +390,12 @@ if (typeof Overlay === "undefined") { if (warmupMin > 0) { // Pre-warmup const warmedUpMinutes = Math.min(minutes, warmupMin); - const warmedUpSeconds = warmedUpMinutes >= warmupMin ? 0 : seconds; + const warmedUpSeconds = minutes >= warmupMin ? 0 : seconds; preWarmup = Math.round((warmupCpm * (warmedUpMinutes + (warmedUpSeconds / 60)))); } // Post-warmup - const trainedMinutes = Math.min(minutes - warmupMin); + const trainedMinutes = Math.min(0, minutes - warmupMin); const trainedSeconds = minutes >= warmupMin ? seconds : 0; const postWarmup = Math.round((cpm * (trainedMinutes + (trainedSeconds / 60))));