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

[fix]binary comparison not working on strings o_o'

This commit is contained in:
Clément 2015-07-25 11:10:11 +02:00
parent d4153bff24
commit c85817edf5

View file

@ -7,7 +7,7 @@ admin_user=$3
# Check user parameter if not empty # Check user parameter if not empty
if [[ $admin_user -ne '' ]]; then if [[ $admin_user != '' ]]; then
sudo yunohost user list --json | grep -qi "\"username\": \"$admin_user\"" sudo yunohost user list --json | grep -qi "\"username\": \"$admin_user\""
if [[ ! $? -eq 0 ]]; then if [[ ! $? -eq 0 ]]; then
echo "Wrong user" echo "Wrong user"
@ -45,7 +45,7 @@ sudo sed -i "s/yunopass/$db_pwd/g" $final_path/data/config.php
sudo sed -i "s/yunobase/$db_user/g" $final_path/data/config.php sudo sed -i "s/yunobase/$db_user/g" $final_path/data/config.php
sudo sed -i "s/yunosalt/$app_salt/g" $final_path/data/config.php sudo sed -i "s/yunosalt/$app_salt/g" $final_path/data/config.php
sudo sed -i "s@yunopath@$path@g" $final_path/data/config.php sudo sed -i "s@yunopath@$path@g" $final_path/data/config.php
if [[ $admin_user -ne '' ]]; then if [[ $admin_user != '' ]]; then
sudo sed -i "s/yunoadminuser/$admin_user/g" $final_path/data/config.php sudo sed -i "s/yunoadminuser/$admin_user/g" $final_path/data/config.php
else else
sudo sed -i '/yunoadminuser/d' $final_path/data/config.php sudo sed -i '/yunoadminuser/d' $final_path/data/config.php