Yes, there is a syntax issue in your array declaration. In Bash, arrays should not have commas between elements. Instead, they should be space-separated. Here’s the corrected version:
x_users=('user_1' 'user_2' 'user_3')
for user in "${x_users[@]}"; do
This should now loop through all three users correctly.