File tree Expand file tree Collapse file tree 1 file changed +9
-4
lines changed
Expand file tree Collapse file tree 1 file changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -48,16 +48,21 @@ if [ "$num_php_versions" -gt 1 ] && [ -z "$WEB_BACKEND" ]; then
4848
4949 # Migrate domains
5050 for user in $( $BIN /v-list-sys-users plain) ; do
51+ # Define user data and get suspended status
52+ USER_DATA=$HESTIA /data/users/$user
53+ SUSPENDED=$( get_user_value ' $SUSPENDED' )
54+
5155 # Check if user is suspended
5256 if [ " $SUSPENDED " = " yes" ]; then
5357 suspended=" yes"
5458 $BIN /v-unsuspend-user $user
5559 fi
5660 echo " Migrating legacy multiphp domains for user: $user "
5761 for domain in $( $BIN /v-list-web-domains $user plain | cut -f1) ; do
62+ SUSPENDED_WEB=$( get_object_value ' web' ' DOMAIN' " $domain " ' $SUSPENDED' )
5863 # Check if web domain is suspended
59- if [ " $SUSPENDED " = " yes" ]; then
60- domain_suspended =" yes"
64+ if [ " $SUSPENDED_WEB " = " yes" ]; then
65+ suspended_web =" yes"
6166 $BIN /v-unsuspend-web-domain $domain
6267 fi
6368 echo " Processing domain: $domain "
@@ -118,8 +123,8 @@ if [ "$num_php_versions" -gt 1 ] && [ -z "$WEB_BACKEND" ]; then
118123 echo -e " --done--\n"
119124
120125 # Suspend domain again, if it was suspended
121- if [ " $domain_suspended " = " yes" ]; then
122- unset domain_suspended
126+ if [ " $suspended_web " = " yes" ]; then
127+ unset suspended_web
123128 $BIN /v-suspend-web-domain $domain
124129 fi
125130 done
You can’t perform that action at this time.
0 commit comments