mirror of
https://github.com/myvesta/vesta
synced 2025-07-06 04:51:54 -07:00
Merge pull request #785 from pcfreak30/hotfix/784
*delete config if domain is not in user web.conf
This commit is contained in:
commit
b0a8ba921e
1 changed files with 2 additions and 2 deletions
|
@ -271,8 +271,8 @@ del_web_config() {
|
||||||
get_web_config_lines $WEBTPL/$1/$WEB_BACKEND/$2 $conf
|
get_web_config_lines $WEBTPL/$1/$WEB_BACKEND/$2 $conf
|
||||||
sed -i "$top_line,$bottom_line d" $conf
|
sed -i "$top_line,$bottom_line d" $conf
|
||||||
|
|
||||||
web_domains=$(grep DOMAIN $USER_DATA/web.conf |wc -l)
|
web_domain=$(grep $domain $USER_DATA/web.conf |wc -l)
|
||||||
if [ "$web_domains" -eq '0' ]; then
|
if [ "$web_domain" -eq '0' ]; then
|
||||||
sed -i "/.*\/$user\/.*$1.conf/d" /etc/$1/conf.d/vesta.conf
|
sed -i "/.*\/$user\/.*$1.conf/d" /etc/$1/conf.d/vesta.conf
|
||||||
rm -f $conf
|
rm -f $conf
|
||||||
fi
|
fi
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue