mirror of
https://github.com/Sebclem/hassio-nextcloud-backup.git
synced 2024-11-09 02:52:58 +01:00
Fix compilation errors
This commit is contained in:
parent
d1fc44be60
commit
8287bdeedc
@ -11,7 +11,7 @@ import {
|
||||
} from "../services/webdavConfigService.js";
|
||||
import { checkWebdavLogin } from "../services/webdavService.js";
|
||||
import type { BackupConfig } from "../types/services/backupConfig.js";
|
||||
import { ValidationError } from "joi";
|
||||
import type { ValidationError } from "joi";
|
||||
import type { WebdavConfig } from "../types/services/webdavConfig.js";
|
||||
|
||||
const configRouter = express.Router();
|
||||
@ -47,9 +47,9 @@ configRouter.put("/webdav", (req, res) => {
|
||||
res.status(204);
|
||||
res.send();
|
||||
})
|
||||
.catch((error) => {
|
||||
.catch((error: ValidationError) => {
|
||||
res.status(400);
|
||||
if (error instanceof ValidationError) {
|
||||
if (error.details) {
|
||||
res.json(error.details);
|
||||
} else {
|
||||
res.json(error);
|
||||
|
@ -3,12 +3,12 @@
|
||||
"compilerOptions": {
|
||||
"allowJs": true,
|
||||
"outDir": "./dist",
|
||||
"module": "NodeNext",
|
||||
"moduleResolution": "NodeNext",
|
||||
"target": "es6",
|
||||
"module": "nodenext",
|
||||
"moduleResolution": "nodenext",
|
||||
"target": "ES2022",
|
||||
"sourceMap": true,
|
||||
"verbatimModuleSyntax": true,
|
||||
"strict": true,
|
||||
"strict": true
|
||||
},
|
||||
"include": ["src/**/*"]
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user