Update helper.js

pull/47/head
Ilya 2023-03-10 11:21:57 +02:00 committed by GitHub
parent 6a73d4f9f4
commit ef42f2ec26
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 3 deletions

View File

@ -14,8 +14,8 @@ export function formatDuration(seconds) {
m = parseInt(m % 60);
}
}
let text = `${s} `;
if (m > 0) text = `${m} ${text}`;
if (h > 0) text = `${h} 小时 ${text}`;
let text = `${s} s`;
if (m > 0) text = `${m} m ${text}`;
if (h > 0) text = `${h} h ${text}`;
return text;
}