From f2fa2109e5fd5dbed236171aea8587cc86b5f302 Mon Sep 17 00:00:00 2001 From: bergware Date: Wed, 11 Jun 2025 23:44:25 +0200 Subject: [PATCH] File manager: fix file overwrite on move operation --- emhttp/plugins/dynamix/nchan/file_manager | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emhttp/plugins/dynamix/nchan/file_manager b/emhttp/plugins/dynamix/nchan/file_manager index fb8612724..076a6b09d 100755 --- a/emhttp/plugins/dynamix/nchan/file_manager +++ b/emhttp/plugins/dynamix/nchan/file_manager @@ -186,7 +186,7 @@ while (true) { } else { $target = validname($target, false); if ($target) { - $f = $exist ? 'f' : 'n'; + $f = $exist ? 'n' : 'f'; exec("mv -{$f}t ".escapeshellarg($target)." ".quoted($source)." 1>$status 2>$error & echo \$!", $pid); } else { $reply['error'] = 'Invalid target name';