How do I get adduserstogroup to fail when it fails to add a user
We need a way to identify when a user fails to get added or removed from an EPM application group.
We are using PowerShell to run our EPM Automate scripts. When we run the addUsersToGroup or removeUsersFromGroup as long as there is no technical issue, the process exits and states that it was successful. However, the details may say that there was a failure to add or remove the user. With PowerShell, we use $LastExitCode to check to see if there was an error. Since EPMAutomate states the command completed successfully even if a user failed to be added or removed, the process does not fail. We need a way to force the process to