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:
parent
4f010f342e
commit
80fd64de92
1 changed files with 3 additions and 2 deletions
|
@ -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
|
||||||
|
|
Loading…
Reference in a new issue