fix: copy/move allow overwrite

This commit is contained in:
Henrique Dias committed 2026-06-06 08:28:31 +02:00
1 parent 5f7311d324
commit a1a514dcbb
8 files changed
+70 -13

No files matched your search

@@ -179,6 +179,7 @@ const drop = async (event: Event) => {
to: props.url + encodeURIComponent(fileStore.req?.items[i].name),
name: fileStore.req?.items[i].name,
size: fileStore.req?.items[i].size,
isDir: fileStore.req?.items[i].isDir,
modified: fileStore.req?.items[i].modified,
overwrite: false,
rename: false,
@@ -204,7 +205,7 @@ const drop = async (event: Event) => {
.catch($showError);
};
const conflict = await upload.checkConflict(items, path);
const conflict = await upload.checkConflict(items, path, true);
if (conflict.length > 0) {
layoutStore.showHover({
+1 -1
View File
@@ -123,7 +123,7 @@ export default {
});
};
const conflict = await upload.checkConflict(items, this.dest);
const conflict = await upload.checkConflict(items, this.dest, true);
if (conflict.length > 0) {
this.showHover({
+1 -1
View File
@@ -123,7 +123,7 @@ export default {
});
};
const conflict = await upload.checkConflict(items, this.dest);
const conflict = await upload.checkConflict(items, this.dest, true);
if (conflict.length > 0) {
this.showHover({
@@ -86,7 +86,8 @@ describe("copy and move conflict prompts", () => {
isDir: false,
}),
],
"/files/target/"
"/files/target/",
true
);
expect(context.showHover).toHaveBeenCalledWith(
expect.objectContaining({
@@ -109,7 +110,8 @@ describe("copy and move conflict prompts", () => {
isDir: false,
}),
],
"/files/target/"
"/files/target/",
true
);
expect(context.showHover).toHaveBeenCalledWith(
expect.objectContaining({