We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 1689ea3 commit ec7994aCopy full SHA for ec7994a
1 file changed
bin/v-add-user
@@ -22,7 +22,7 @@ source $VESTA/func/main.sh
22
source $VESTA/conf/vesta.conf
23
24
is_user_free() {
25
- check_sysuser=$(cut -f 1 -d : /etc/passwd | grep -w "$user" )
+ check_sysuser=$(cut -f 1 -d : /etc/passwd | grep "^$user$" )
26
if [ ! -z "$check_sysuser" ] || [ -e "$USER_DATA" ]; then
27
echo "Error: user $user exists"
28
log_event "$E_EXISTS" "$EVENT"
0 commit comments