@@ -137,7 +137,7 @@ export const dateFormat = (value: string | Date, format = 'YYYY-MM-DD HH:mm:ss')
// 秒转分
export const getSecondRPM = (second: number, type?: string) => {
- if (isNaN(second)) return '00:00'
+ if (isNaN(second) || second < 0) return '00:00'
const mm = Math.floor(second / 60)
.toString()
.padStart(2, '0')
@@ -20,7 +20,7 @@ import useErrorLog from '@/hooks/useErrorLog';