1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/freshrss_ynh.git synced 2024-09-03 18:36:33 +02:00

modify path check

This commit is contained in:
Clément 2017-03-13 23:08:35 +01:00
parent 4f010f342e
commit 80fd64de92

View file

@ -20,10 +20,11 @@ FINAL_PATH="/var/www/$app"
# Source app helpers # Source app helpers
. /usr/share/yunohost/helpers . /usr/share/yunohost/helpers
# copy past from nextcloud package # if path do not begin with / add a / at the begining
if [ "${path:0:1}" != "/" ] && [ ${#path} -gt 0 ]; then if [ "${path:0:1}" != "/" ]; then
path="/$path" path="/$path"
fi fi
# if path do not end with / add a / at the end
if [ "${path:${#path}-1}" == "/" ] && [ ${#path} -gt 1 ]; then if [ "${path:${#path}-1}" == "/" ] && [ ${#path} -gt 1 ]; then
path="${path:0:${#path}-1}" path="${path:0:${#path}-1}"
fi fi