Only consider the last line

Since other console output may occur during add
This commit is contained in:
Bob Mottram 2016-11-20 10:47:57 +00:00
parent b8c0bce0f1
commit 7a3c40d921
1 changed files with 1 additions and 1 deletions

View File

@ -209,7 +209,7 @@ do
if [[ $(function_exists add_user_${app_name}) == "1" ]]; then
echo $"Adding user to ${app_name}"
app_load_variables ${app_name}
retval=$(add_user_${app_name} "$ADD_USERNAME" "$NEW_USER_PASSWORD")
retval=$(add_user_${app_name} "$ADD_USERNAME" "$NEW_USER_PASSWORD" | tail -n 1)
if [[ $retval != '0' ]]; then
echo $"Failed with error code ${retval}"
${PROJECT_NAME}-rmuser $ADD_USERNAME --force