rm-prefer-trash: fix trashdir being unset in some cases

This commit is contained in:
PowerUser64 2025-03-24 23:25:35 -07:00
parent 51616211d8
commit 3eaa2828ba

View file

@ -110,9 +110,9 @@ do_rmtrash() {
fi
fi
done
trashdir=''
if [ "$fs1" != '' ]; then
# if we get here, we have validated that all the files are on the same filesystem
trashdir=''
found_trash=false
while [ "$trashdirs" != "$trashdir" ]; do
trashdir="${trashdirs%%:*}"