premiumizeme: fix server side move after API change

See: https://forum.rclone.org/t/premiumize-cant-move-files/27169
See: #5734
This commit is contained in:
Nick Craig-Wood 2021-10-31 16:26:33 +00:00
parent f85e3209b3
commit af705c754c

View file

@ -653,10 +653,11 @@ func (f *Fs) move(ctx context.Context, isFile bool, id, oldLeaf, newLeaf, oldDir
"id": {newDirectoryID}, "id": {newDirectoryID},
}, },
} }
opts.MultipartParams.Set("items[0][id]", id)
if isFile { if isFile {
opts.MultipartParams.Set("files[]", id) opts.MultipartParams.Set("items[0][type]", "file")
} else { } else {
opts.MultipartParams.Set("folders[]", id) opts.MultipartParams.Set("items[0][type]", "folder")
} }
//replacedLeaf := enc.FromStandardName(leaf) //replacedLeaf := enc.FromStandardName(leaf)
var resp *http.Response var resp *http.Response