Fixing application undeployment logic in autosclaer service