setup.sh: avoid subshells: type -t
This commit is contained in:
parent
463463b395
commit
6f024f6e65
@ -98,7 +98,7 @@ _callImplicitHook() {
|
|||||||
# hooks exits the hook, not the caller. Also will only pass args if
|
# hooks exits the hook, not the caller. Also will only pass args if
|
||||||
# command can take them
|
# command can take them
|
||||||
_eval() {
|
_eval() {
|
||||||
if [ "$(type -t "$1")" = function ]; then
|
if declare -F "$1" > /dev/null 2>&1; then
|
||||||
set +u
|
set +u
|
||||||
"$@" # including args
|
"$@" # including args
|
||||||
else
|
else
|
||||||
|
Loading…
x
Reference in New Issue
Block a user