Only chown download and watch folders if permissions are wrong

This commit is contained in:
TheSpad
2022-11-03 11:28:59 +00:00
parent 216edd44dc
commit 7f034d3763

View File

@@ -43,7 +43,11 @@ fi
# permissions
chown abc:abc \
/config/settings.json \
/downloads \
/downloads/complete \
/downloads/incomplete \
/watch
if [[ "$(stat -c '%U' /downloads)" != "abc" ]]; then
chown abc:abc /downloads
fi
if [[ "$(stat -c '%U' /watch)" != "abc" ]]; then
chown abc:abc /watch
fi