Ensure replace dialog shown for renames

This commit is contained in:
Jeremy Soller 2025-07-11 09:37:28 -06:00
parent f3c8182966
commit 5a01fb95ff
No known key found for this signature in database
GPG key ID: 670FDFB5428E05CA

View file

@ -310,6 +310,11 @@ async fn copy_or_move(
//TODO: allow rename to be used for directories in recursive context?
if matches!(method, Method::Move { .. }) {
from_to_pairs.retain(|(from, to)| {
//TODO: show replace dialog here?
if to.exists() {
return true;
}
//TODO: use compio::fs::rename?
match fs::rename(from, to) {
Ok(()) => {