File tree Expand file tree Collapse file tree 3 files changed +8
-0
lines changed
Expand file tree Collapse file tree 3 files changed +8
-0
lines changed Original file line number Diff line number Diff line change @@ -57,6 +57,11 @@ rm -rf $HOMEDIR/$user/mail/$domain/$account
5757# Update config
5858sed -i " /ACCOUNT='$account '/d" $USER_DATA /mail/$domain .conf
5959
60+ # Decrease mail accounts counter
61+ accounts=$( wc -l $USER_DATA /mail/$domain .conf | cut -f 1 -d ' ' )
62+ decrease_user_value " $user " ' $U_MAIL_ACCOUNTS'
63+ update_object_value ' mail' ' DOMAIN' " $domain " ' $ACCOUNTS' " $accounts "
64+
6065
6166# Logging
6267log_history " $EVENT "
Original file line number Diff line number Diff line change @@ -48,6 +48,7 @@ rm -f /etc/exim/domains/$domain
4848
4949# Updating config
5050update_object_value ' mail' ' DOMAIN' " $domain " ' $SUSPENDED' ' yes'
51+ sed -i " s/SUSPENDED='no'/SUSPENDED='yes'/g" $USER_DATA /mail/$domain .conf
5152
5253# Logging
5354log_event " $OK " " $EVENT "
Original file line number Diff line number Diff line change @@ -47,6 +47,8 @@ ln -s $HOMEDIR/$user/conf/mail/$domain /etc/exim/domains/
4747
4848# Updating config
4949update_object_value ' mail' ' DOMAIN' " $domain " ' $SUSPENDED' ' no'
50+ sed -i " s/SUSPENDED='yes'/SUSPENDED='no'/g" $USER_DATA /mail/$domain .conf
51+
5052
5153# Logging
5254log_event " $OK " " $EVENT "
You can’t perform that action at this time.
0 commit comments