Commit Graph

4377 Commits

Author SHA1 Message Date
Nextcloud bot dec7927eb8
[tx-robot] updated from transifex 2019-02-14 01:12:55 +00:00
Nextcloud bot 5949288dd4
[tx-robot] updated from transifex 2019-02-13 01:12:44 +00:00
Nextcloud bot c3c8086c4a
[tx-robot] updated from transifex 2019-02-12 01:12:56 +00:00
Nextcloud bot 50634e82ef
[tx-robot] updated from transifex 2019-02-11 01:12:49 +00:00
Nextcloud bot 560f178f39
[tx-robot] updated from transifex 2019-02-10 01:13:56 +00:00
Nextcloud bot 79471e8d4a
[tx-robot] updated from transifex 2019-02-08 01:13:06 +00:00
Nextcloud bot 5b152acf73
[tx-robot] updated from transifex 2019-02-06 22:18:50 +00:00
Nextcloud bot e965465f6b
[tx-robot] updated from transifex 2019-02-06 11:28:01 +00:00
Daniel Calviño Sánchez 036bfa08dd Fix dropping a folder on a folder row
When the uploaded files have a relative path (that is, when a folder is
uploaded) it is first ensured that all the parent folders exist, which
is done by trying to create them. When a folder is created in the
currently opened folder the file list is updated and a row for the new
folder is added. However, this was done too when the folder already
existed, which caused the previous row to be removed and a new one added
to replace it.

For security reasons, some special headers need to be set in requests;
this is done automatically for jQuery by handling the "ajaxSend" event
in the document. In the case of DAV requests, if the headers are not set
the server rejects the request with "CSRF check not passed".

When a file or folder is dropped on a folder row the jQuery upload
events are chained from the initial drop event, which has the row as its
target. In order to upload the file jQuery performs a request, which
triggers the "ajaxSend" event in the row; this event then bubbles up to
the document, which is then handled by adding the special headers to the
request.

However, when a folder was dropped on a folder row that folder row was
removed when ensuring that the folder exists. The jQuery upload events
were still triggered on the row, but as it had been removed it had no
parent nodes, and thus the events did not bubble up. Due to this the
"ajaxSend" event never reached the document when triggered on the
removed row, the headers were not set, and the upload failed.

All this is simply fixed by not removing the folder row when trying to
create it if it existed already.

Signed-off-by: Daniel Calviño Sánchez <danxuliu@gmail.com>
2019-01-29 14:49:26 +00:00
Nextcloud bot e898c52eb0
[tx-robot] updated from transifex 2019-01-22 01:12:55 +00:00
Nextcloud bot 1a4d519593
[tx-robot] updated from transifex 2019-01-19 01:12:49 +00:00
Nextcloud bot c610182204
[tx-robot] updated from transifex 2019-01-17 01:12:49 +00:00
Nextcloud bot 6a7624067b
[tx-robot] updated from transifex 2019-01-16 01:13:05 +00:00
Nextcloud bot d9a29dc4b4
[tx-robot] updated from transifex 2019-01-15 01:12:45 +00:00
Nextcloud bot dcd1dbb609
[tx-robot] updated from transifex 2019-01-14 01:12:28 +00:00
Nextcloud bot d9326a93b9
[tx-robot] updated from transifex 2019-01-13 01:13:22 +00:00
Nextcloud bot 2b5786b45e
[tx-robot] updated from transifex 2019-01-12 01:12:25 +00:00
Nextcloud bot 6be08ad0de
[tx-robot] updated from transifex 2019-01-11 01:12:59 +00:00
Nextcloud bot 88455103fd
[tx-robot] updated from transifex 2019-01-08 01:12:30 +00:00
Nextcloud bot a150a986ce
[tx-robot] updated from transifex 2019-01-06 01:13:33 +00:00
Nextcloud bot 14c8416685
[tx-robot] updated from transifex 2019-01-05 01:12:27 +00:00
Nextcloud bot 4cd18afb29
[tx-robot] updated from transifex 2019-01-04 01:12:57 +00:00
Nextcloud bot 93923fbe49
[tx-robot] updated from transifex 2019-01-01 01:12:04 +00:00
Nextcloud bot fcae962594
[tx-robot] updated from transifex 2018-12-31 01:12:11 +00:00
Nextcloud bot 2ad10aa7a2
[tx-robot] updated from transifex 2018-12-30 01:13:11 +00:00
Nextcloud bot aa4a4d4415
[tx-robot] updated from transifex 2018-12-28 01:12:15 +00:00
Nextcloud bot 0e03a5c839
[tx-robot] updated from transifex 2018-12-27 01:12:12 +00:00
Nextcloud bot ae2f588305
[tx-robot] updated from transifex 2018-12-26 01:12:24 +00:00
Nextcloud bot 224dbe15fd
[tx-robot] updated from transifex 2018-12-24 01:12:15 +00:00
Nextcloud bot 69798a20a4
[tx-robot] updated from transifex 2018-12-21 01:12:15 +00:00
Nextcloud bot b677dadf18
[tx-robot] updated from transifex 2018-12-20 01:12:13 +00:00
Nextcloud bot daea45c424
[tx-robot] updated from transifex 2018-12-19 01:12:16 +00:00
Nextcloud bot a730ad16f1
[tx-robot] updated from transifex 2018-12-17 01:11:59 +00:00
Nextcloud bot 90bd295d3c
[tx-robot] updated from transifex 2018-12-16 01:12:59 +00:00
Nextcloud bot c2d7f88fdf
[tx-robot] updated from transifex 2018-12-15 01:12:04 +00:00
Nextcloud bot f360b8df0b
[tx-robot] updated from transifex 2018-12-12 01:12:04 +00:00
Nextcloud bot e545bcd54d
[tx-robot] updated from transifex 2018-12-05 01:12:23 +00:00
Nextcloud bot 0d5f3d16e9
[tx-robot] updated from transifex 2018-12-04 01:12:34 +00:00
Nextcloud bot 9a48fdd5e8
[tx-robot] updated from transifex 2018-12-03 01:12:00 +00:00
Nextcloud bot 2e09bb48fb
[tx-robot] updated from transifex 2018-11-30 01:12:26 +00:00
Nextcloud bot 8f80685426
[tx-robot] updated from transifex 2018-11-29 01:12:00 +00:00
Nextcloud bot e389bf4588
[tx-robot] updated from transifex 2018-11-28 01:12:24 +00:00
Nextcloud bot eca49de335
[tx-robot] updated from transifex 2018-11-27 01:11:59 +00:00
Nextcloud bot fffed81800
[tx-robot] updated from transifex 2018-11-26 01:11:49 +00:00
Nextcloud bot c741fe5aed
[tx-robot] updated from transifex 2018-11-25 01:12:42 +00:00
Nextcloud bot 537694fc60
[tx-robot] updated from transifex 2018-11-24 01:11:47 +00:00
Nextcloud bot ca4abe8da6
[tx-robot] updated from transifex 2018-11-23 01:13:30 +00:00
Nextcloud bot 98c7accec8
[tx-robot] updated from transifex 2018-11-18 01:13:17 +00:00
Nextcloud bot 24a04fae3d
[tx-robot] updated from transifex 2018-11-16 01:12:34 +00:00
Nextcloud bot c2000c295c
[tx-robot] updated from transifex 2018-11-15 01:12:32 +00:00