forked from mirrors/homebox
feat: add scheduled maintenance tasks (#320)
* add scheduled maintenance tasks * fix failing typecheck
This commit is contained in:
parent
70297b9d27
commit
025521431e
25 changed files with 521 additions and 121 deletions
|
@ -5,6 +5,10 @@ export function validDate(dt: Date | string | null | undefined): boolean {
|
|||
|
||||
// If it's a string, try to parse it
|
||||
if (typeof dt === "string") {
|
||||
if (dt.startsWith("0001")) {
|
||||
return false;
|
||||
}
|
||||
|
||||
const parsed = new Date(dt);
|
||||
if (isNaN(parsed.getTime())) {
|
||||
return false;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue