Skip to content

Commit

Permalink
FIX PROD ERROR
Browse files Browse the repository at this point in the history
  • Loading branch information
ayanamirei committed Feb 13, 2024
1 parent 0be324a commit d7963e5
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions composables/formatTime.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { format } from 'date-fns'
import { zhCN } from 'date-fns/locale'

export function formatTime(data: string | undefined | null | Date) {
if (data)
Expand All @@ -10,7 +9,7 @@ export function formatTime(data: string | undefined | null | Date) {

export function formatZHTime(data: string | undefined | null | Date) {
if (data)
return format(new Date(data), 'yyyy年MM月dd日', { locale: zhCN })
return format(new Date(data), 'yyyy年MM月dd日')
else
return ''
}

0 comments on commit d7963e5

Please sign in to comment.