The '[[ -z' test in in_array() doesn't really do anything, so I'm
removing it. I think this is much cleaner.

Signed-off-by: DJ Mills <[email protected]>
---
 scripts/makepkg.sh.in |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)

diff --git a/scripts/makepkg.sh.in b/scripts/makepkg.sh.in
index 1b132a9..e215c4b 100644
--- a/scripts/makepkg.sh.in
+++ b/scripts/makepkg.sh.in
@@ -318,10 +318,8 @@ in_opt_array() {
 #          1 - not found
 ##
 in_array() {
-       local needle=$1; shift
-       [[ -z $1 ]] && return 1 # Not Found
-       local item
-       for item in "$@"; do
+       local needle=$1 item; shift
+       for item; do
                [[ $item = $needle ]] && return 0 # Found
        done
        return 1 # Not Found
-- 
1.7.6


Reply via email to