Fix bug in contains function
darcs-hash:20061009215133-ac50b-3dc99c245e69c176f334046d9746d533a106cf2a.gz
This commit is contained in:
parent
e11677ef66
commit
007e4662e3
@ -1,6 +1,6 @@
|
||||
|
||||
function contains -d (N_ "Test if a key is contained in a set of values")
|
||||
while set -q argv
|
||||
while count $argv >/dev/null
|
||||
switch $argv[1]
|
||||
case '-h' '--h' '--he' '--hel' '--help'
|
||||
help contains
|
||||
@ -24,7 +24,7 @@ function contains -d (N_ "Test if a key is contained in a set of values")
|
||||
set -e argv[1]
|
||||
end
|
||||
|
||||
if not set -q argv
|
||||
if not count $argv >/dev/null
|
||||
printf (_ "%s: Key not specified\n") contains
|
||||
return 1
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user