Browse Source

Enable webmail access when unsuspending mail domain

Kristan Kenney 6 years ago
parent
commit
f08af08696
1 changed files with 3 additions and 3 deletions
  1. 3 3
      bin/v-unsuspend-mail-domain

+ 3 - 3
bin/v-unsuspend-mail-domain

@@ -46,9 +46,6 @@ if [[ "$MAIL_SYSTEM" =~ exim ]]; then
     ln -s $HOMEDIR/$user/conf/mail/$domain /etc/$MAIL_SYSTEM/domains/
 fi
 
-# Enable webmail access
-$BIN/v-add-webmail $user $domain 'yes'
-
 #----------------------------------------------------------#
 #                       Hestia                             #
 #----------------------------------------------------------#
@@ -58,6 +55,9 @@ update_object_value 'mail' 'DOMAIN' "$domain" '$SUSPENDED' 'no'
 sed -i "s/SUSPENDED='yes'/SUSPENDED='no'/g" $USER_DATA/mail/$domain.conf
 decrease_user_value "$user" '$SUSPENDED_MAIL'
 
+# Enable webmail access
+$BIN/v-add-webmail $user $domain 'yes'
+
 # Logging
 log_event "$OK" "$ARGUMENTS"