fix #1305: WebDAV issues

This commit is contained in:
antelle 2019-10-15 20:02:44 +02:00
parent bc4dbc7de2
commit be79f67510
2 changed files with 21 additions and 18 deletions

View File

@ -100,9 +100,9 @@ class StorageWebDav extends StorageBase {
const that = this;
this._request(
{
...saveOpts,
op: 'Save:stat',
method: 'HEAD',
...saveOpts
method: 'HEAD'
},
(err, xhr, stat) => {
let useTmpPath = this.appSettings.webdavSaveMethod !== 'put';
@ -120,12 +120,12 @@ class StorageWebDav extends StorageBase {
if (useTmpPath) {
that._request(
{
...saveOpts,
op: 'Save:put',
method: 'PUT',
path: tmpPath,
data,
nostat: true,
...saveOpts
nostat: true
},
err => {
if (err) {
@ -133,17 +133,17 @@ class StorageWebDav extends StorageBase {
}
that._request(
{
...saveOpts,
op: 'Save:stat',
method: 'HEAD',
...saveOpts
method: 'HEAD'
},
(err, xhr, stat) => {
if (err) {
that._request({
...saveOpts,
op: 'Save:delete',
method: 'DELETE',
path: tmpPath,
...saveOpts
path: tmpPath
});
return cb(err, xhr, stat);
}
@ -156,10 +156,10 @@ class StorageWebDav extends StorageBase {
rev
);
that._request({
...saveOpts,
op: 'Save:delete',
method: 'DELETE',
path: tmpPath,
...saveOpts
path: tmpPath
});
return cb({ revConflict: true }, xhr, stat);
}
@ -176,6 +176,7 @@ class StorageWebDav extends StorageBase {
}
that._request(
{
...saveOpts,
op: 'Save:move',
method: 'MOVE',
path: tmpPath,
@ -183,8 +184,7 @@ class StorageWebDav extends StorageBase {
headers: {
Destination: encodeURI(movePath),
'Overwrite': 'T'
},
...saveOpts
}
},
err => {
if (err) {
@ -192,9 +192,9 @@ class StorageWebDav extends StorageBase {
}
that._request(
{
...saveOpts,
op: 'Save:stat',
method: 'HEAD',
...saveOpts
method: 'HEAD'
},
(err, xhr, stat) => {
cb(err, xhr, stat);
@ -209,11 +209,11 @@ class StorageWebDav extends StorageBase {
} else {
that._request(
{
...saveOpts,
op: 'Save:put',
method: 'PUT',
data,
nostat: true,
...saveOpts
nostat: true
},
err => {
if (err) {
@ -221,9 +221,9 @@ class StorageWebDav extends StorageBase {
}
that._request(
{
...saveOpts,
op: 'Save:stat',
method: 'HEAD',
...saveOpts
method: 'HEAD'
},
(err, xhr, stat) => {
cb(err, xhr, stat);

View File

@ -1,5 +1,8 @@
Release notes
-------------
##### v1.11.10 (2019-10-15)
`-` fix #1305: WebDAV issues
##### v1.11.9 (2019-10-13)
`-` fix #1300: selecting auto-type sequence items issues
`-` fix #1290: generator popup positioning in custom themes