add no-cache for webdav
This commit is contained in:
parent
d3d26bfe49
commit
bfa23eb8a5
@ -183,6 +183,9 @@ export class WrappedWebdavClient {
|
|||||||
|
|
||||||
init = async () => {
|
init = async () => {
|
||||||
// init client if not inited
|
// init client if not inited
|
||||||
|
const headers = {
|
||||||
|
"Cache-Control": "no-cache",
|
||||||
|
};
|
||||||
if (this.client === undefined) {
|
if (this.client === undefined) {
|
||||||
if (
|
if (
|
||||||
this.webdavConfig.username !== "" &&
|
this.webdavConfig.username !== "" &&
|
||||||
@ -191,6 +194,7 @@ export class WrappedWebdavClient {
|
|||||||
this.client = createClient(this.webdavConfig.address, {
|
this.client = createClient(this.webdavConfig.address, {
|
||||||
username: this.webdavConfig.username,
|
username: this.webdavConfig.username,
|
||||||
password: this.webdavConfig.password,
|
password: this.webdavConfig.password,
|
||||||
|
headers: headers,
|
||||||
authType:
|
authType:
|
||||||
this.webdavConfig.authType === "digest"
|
this.webdavConfig.authType === "digest"
|
||||||
? AuthType.Digest
|
? AuthType.Digest
|
||||||
@ -198,7 +202,9 @@ export class WrappedWebdavClient {
|
|||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
log.info("no password");
|
log.info("no password");
|
||||||
this.client = createClient(this.webdavConfig.address);
|
this.client = createClient(this.webdavConfig.address, {
|
||||||
|
headers: headers,
|
||||||
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user