Skip to content

Commit 1c19492

Browse files
committed
Prevent to return multiple values if user conf contains more than one equal vars.
1 parent 06a1572 commit 1c19492

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

func/main.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ search_objects() {
338338

339339
# Get user value
340340
get_user_value() {
341-
grep "^${1//$/}=" $USER_DATA/user.conf |awk -F "'" '{print $2}'
341+
grep "^${1//$/}=" $USER_DATA/user.conf | head -1 | awk -F "'" '{print $2}'
342342
}
343343

344344
# Update user value in user.conf

0 commit comments

Comments
 (0)