Environment for "Command to run after making changes to an alias" not cleared from previous call when deleting domains

When deleting a virtual domain in which multiple users still exist “Command to run after making changes to an alias” is called multiple times sequentially. It appears that the environment is not cleared between calls.

Therefore, if a call in which certain variables are set is followed by a call in which the same variables are not explicitly set then the subsequent calls retain the variables’ contents from the last call to set the variables through as many calls as occur until the variables are explicitly set.

For example, when deleting a domain with multiple mail users defined in LDAP the last calls to “Command to run after making changes to an alias” made to delete the virtual server user and aliases contain the “USERADMIN_LDAP_*” and some of the “USERADMIN_*” variables from the last mail user deleted.

Is this intentional?

Sounds like it may be a bug!

I’d recommend filing a support request using the Support link above.