From b0acde0ba63ba275034070cbcc8d26d92f4e5770 Mon Sep 17 00:00:00 2001 From: fyears <1142836+fyears@users.noreply.github.com> Date: Sun, 19 May 2024 20:36:34 +0800 Subject: [PATCH] remove recursive to fix digest --- src/fsWebdav.ts | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/fsWebdav.ts b/src/fsWebdav.ts index f2d8b03..486d3fd 100644 --- a/src/fsWebdav.ts +++ b/src/fsWebdav.ts @@ -459,8 +459,10 @@ export class FakeFsWebdav extends FakeFs { mtime?: number, ctime?: number ): Promise { + // the sync algorithm should do recursive manually already. + // if we set recursive: true here, Digest auth will return some error inside the PROPFIND await this.client.createDirectory(key, { - recursive: true, + recursive: false, }); return await this._statFromRoot(key); } @@ -531,7 +533,13 @@ export class FakeFsWebdav extends FakeFs { // throw e; this.isNextcloud = false; this.supportNativePartial = false; - return await this._writeFileFromRootFull(key, content, mtime, ctime, origKey); + return await this._writeFileFromRootFull( + key, + content, + mtime, + ctime, + origKey + ); } }