fix: expired check 2.0?
This commit is contained in:
parent
f0f8a6f01b
commit
2797525969
@ -49,6 +49,7 @@ export default function Page() {
|
||||
useLiveData({ interval: 1000 })
|
||||
|
||||
const expired = machine.expiry === '0001-01-01 00:00:00'
|
||||
|| machine.expiry === '0001-01-01T00:00:00Z'
|
||||
? false
|
||||
: new Date(machine.expiry).getTime() < Date.now()
|
||||
|
||||
|
||||
@ -17,6 +17,7 @@ interface Props {
|
||||
|
||||
export default function MachineRow({ machine, routes, magic }: Props) {
|
||||
const expired = machine.expiry === '0001-01-01 00:00:00'
|
||||
|| machine.expiry === '0001-01-01T00:00:00Z'
|
||||
? false
|
||||
: new Date(machine.expiry).getTime() < Date.now()
|
||||
|
||||
|
||||
@ -23,6 +23,7 @@ export default function Menu({ machine, routes, magic }: MenuProps) {
|
||||
const routesState = useState(false)
|
||||
|
||||
const expired = machine.expiry === '0001-01-01 00:00:00'
|
||||
|| machine.expiry === '0001-01-01T00:00:00Z'
|
||||
? false
|
||||
: new Date(machine.expiry).getTime() < Date.now()
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user