diff options
author | Ajay Ramachandran <[email protected]> | 2020-02-11 20:33:04 -0500 |
---|---|---|
committer | GitHub <[email protected]> | 2020-02-11 20:33:04 -0500 |
commit | 1f10bdf59301998e6aeb32e5c111e6a597798ad2 (patch) | |
tree | 899f9ceccb750b9fb1d2103817daa9a7eacdaac4 | |
parent | c4da85340ac9e2fa15559e42d870f3f2e2fc03c0 (diff) | |
parent | 3b543916ffd7c2ef1709c1aee1aff53563fcda00 (diff) | |
download | SponsorBlock-1f10bdf59301998e6aeb32e5c111e6a597798ad2.tar.gz SponsorBlock-1f10bdf59301998e6aeb32e5c111e6a597798ad2.zip |
Merge pull request #279 from CommanderRoot/patch-1
Retain decimals in seconds value when editing sponsor times
-rw-r--r-- | src/popup.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/popup.ts b/src/popup.ts index e47edf31..c61a0a5d 100644 --- a/src/popup.ts +++ b/src/popup.ts @@ -671,7 +671,7 @@ async function runThePopup(messageListener?: MessageListener) { let minutes = <HTMLInputElement> <unknown> document.getElementById(idStartName + "Minutes" + index); let seconds = <HTMLInputElement> <unknown> document.getElementById(idStartName + "Seconds" + index); - return parseInt(minutes.value) * 60 + parseInt(seconds.value); + return parseInt(minutes.value) * 60 + parseFloat(seconds.value); } function saveSponsorTimeEdit(index, closeEditMode = true) { @@ -1128,4 +1128,4 @@ if (chrome.tabs != undefined) { runThePopup(); } -export default runThePopup;
\ No newline at end of file +export default runThePopup; |