Update 00-folders.sh

This commit is contained in:
Alexandre
2022-05-19 18:35:10 +02:00
committed by GitHub
parent 08b6a31fee
commit c56458c9ee

View File

@@ -49,7 +49,7 @@ change_folders () {
chown -R "$PUID":"$PGID" "$CONFIGLOCATION"
# Transfer files
if [ -d "$ORIGINALLOCATION" ] && [ "$(ls -A $ORIGINALLOCATION)" ]; then
if [ -d "$ORIGINALLOCATION" ] && [ "$(ls -A $ORIGINALLOCATION 2>/dev/null)" ]; then
echo "Files were existing in $ORIGINALLOCATION, they will be moved to $CONFIGLOCATION"
mv "$ORIGINALLOCATION"/* "$CONFIGLOCATION"/
rmdir "$ORIGINALLOCATION"