utils.sh: fixed function_exists not to display grep result
This commit is contained in:
@@ -26,8 +26,11 @@ function_exists() {
|
|||||||
die 11 --force
|
die 11 --force
|
||||||
fi
|
fi
|
||||||
|
|
||||||
LC_ALL=C type -t $1 | grep function
|
if [[ $(LC_ALL=C type -t $1 | grep function) ]]; then
|
||||||
return $?
|
return 0
|
||||||
|
else
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
export -f function_exists
|
export -f function_exists
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user