This commit is contained in:
cooper 2020-03-08 13:56:49 +08:00 committed by GitHub
parent a45e64fcb2
commit 188ff03a28
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -14,7 +14,7 @@ export function parseTime(time, cFormat) {
}
const format = cFormat || '{y}-{m}-{d} {h}:{i}:{s}'
let date
if (typeof time === 'object') {
if (typeof time === 'object' && time != null) {
date = time
} else {
if ((typeof time === 'string') && (/^[0-9]+$/.test(time))) {