refactor Setting

This commit is contained in:
Timi
2026-04-30 11:04:28 +08:00
parent 28f0eabff2
commit ff3297e879
15 changed files with 239 additions and 231 deletions
+2 -2
View File
@@ -92,8 +92,8 @@ export default class Time {
return { l, y, d, h, m, s, ms };
}
public static duration(totalMs?: number, ms?: boolean): string {
if (!totalMs) {
public static duration(totalMs?: number | null | undefined, ms?: boolean): string {
if (totalMs === null || totalMs === undefined) {
return "";
}
let remain = Math.floor(totalMs);