I can't understand why userType is not changing.
I know for certain it's successfully reaching determineType, but it isn't changing the value to "bbb" when I try to print out userType later.
userType="aaa"
function determineType {
userType="bbb"
}
function checkUser {
cat users.csv | \
while read userLine; do
if [[ $userLine =~ .*$user.* ]]
then
determineType
echo "1"
fi
done
echo "0"
}