smbserver - also delete empty folders when emptying the recycle bin (#2222)

Signed-off-by: szaimen <szaimen@e.mail.de>
This commit is contained in:
Simon L 2022-02-05 21:15:35 +01:00 committed by GitHub
parent 1c346036ee
commit 98dd5ca2b5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1370,6 +1370,7 @@ do
if [ -d "\$SMB_PATH" ] && [ -d "\$SMB_PATH/.recycle/" ]
then
find "\$SMB_PATH/.recycle/" -type f -atime +2 -delete
find "\$SMB_PATH/.recycle/" -empty -delete
fi
fi
count=\$((count+1))