mirror of
https://github.com/Lissy93/dashy.git
synced 2024-11-27 00:28:09 +03:00
🐛 Correct DeepScan issue.
This commit is contained in:
parent
7280820ba5
commit
f46bcc2edd
@ -153,7 +153,7 @@ export const getTimeDifference = (startTime, endTime) => {
|
||||
];
|
||||
|
||||
for (let idx = 0; idx < periods.length; idx += 1) {
|
||||
if (diff < periods[idx + 1]?.value ?? Infinity) {
|
||||
if (diff < (periods[idx + 1]?.value ?? Infinity)) {
|
||||
const period = periods[idx];
|
||||
const value = divide(diff, period.value);
|
||||
const noun = value === 1 ? period.noun : `${period.noun}s`;
|
||||
|
Loading…
Reference in New Issue
Block a user