Update web-dav-api.service.ts

This commit is contained in:
Boring3 2024-09-10 22:12:40 +08:00 committed by Johannes Millan
parent 371ef42d95
commit 93e01ae212

View file

@ -99,7 +99,7 @@ export class WebDavApiService {
const cfg = await this._cfg$.pipe(first()).toPromise();
if (IS_ANDROID_WEB_VIEW && androidInterface.makeHttpRequest) {
const result = (await androidInterface.makeHttpRequestWrapped(
cfg.baseUrl + '/' + path,
new URL(path, cfg.baseUrl).toString(),
'PUT',
data,
// JSON.stringify(data),
@ -128,7 +128,7 @@ export class WebDavApiService {
if (IS_ANDROID_WEB_VIEW && androidInterface.makeHttpRequest) {
// TODO check on real android
const result = (await androidInterface.makeHttpRequestWrapped(
cfg.baseUrl + '/' + folderPath,
new URL(folderPath, cfg.baseUrl).toString(),
'MKCOL',
'',
cfg.userName,
@ -154,7 +154,7 @@ export class WebDavApiService {
const cfg = await this._cfg$.pipe(first()).toPromise();
if (IS_ANDROID_WEB_VIEW && androidInterface.makeHttpRequest) {
const result = (await androidInterface.makeHttpRequestWrapped(
cfg.baseUrl + '/' + path,
new URL(path, cfg.baseUrl).toString(),
'HEAD',
'',
cfg.userName,
@ -188,7 +188,7 @@ export class WebDavApiService {
const cfg = await this._cfg$.pipe(first()).toPromise();
if (IS_ANDROID_WEB_VIEW && androidInterface.makeHttpRequest) {
const result = (await androidInterface.makeHttpRequestWrapped(
cfg.baseUrl + '/' + path,
new URL(path, cfg.baseUrl).toString(),
'GET',
'',
cfg.userName,