summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/core/libs/lib-misc.sh6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/core/libs/lib-misc.sh b/src/core/libs/lib-misc.sh
index ef7a000..c30e4cb 100644
--- a/src/core/libs/lib-misc.sh
+++ b/src/core/libs/lib-misc.sh
@@ -50,7 +50,7 @@ wait_for ()
# $2 set (array) haystack
check_is_in ()
{
- [ -z "$1" ] && debug 'MISC' "check_is_in $1 $2" && die_error "check_is_in needs a non-empty needle as \$1 and a haystack as \$2!" # haystack can be empty though
+ [ -z "$1" ] && die_error "check_is_in needs a non-empty needle as \$1 and a haystack as \$2!(got: check_is_in '$1' '$2'" # haystack can be empty though
NEEDLE=$1
HAYSTACK=$2
@@ -58,10 +58,8 @@ check_is_in ()
shift
for element
do
- [[ $element = $pattern ]] && debug 'MISC' "Checking if $element = $pattern ..yes !" && return 0
- debug 'MISC' "Checking if $element = $pattern ... no"
+ [[ $element = $pattern ]] && return 0
done
- debug 'MISC' "Check_is_in could not find $NEEDLE in $HAYSTACK"
return 1
}