From eede5b7666c47306ca99894641a9dcee41ccaa5c Mon Sep 17 00:00:00 2001 From: gk Date: Tue, 13 Oct 2020 07:10:12 +1000 Subject: [PATCH] less obfuscation in eq() --- fet.sh | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/fet.sh b/fet.sh index eaa4830..bc836cb 100755 --- a/fet.sh +++ b/fet.sh @@ -9,10 +9,9 @@ exec 2>/dev/null set -- eq() { # equals | [ a = b ] with globbing case $1 in - # if the second argument matches the first, exit normally - $2) return - # if it doesn't match, reverse the output of `:`, which makes an error - esac;! : + $2) ;; + *) return 1;; + esac } ## DE