Skip to content

Commit

Permalink
why doesn't zsh set the curlopt array properly?
Browse files Browse the repository at this point in the history
  • Loading branch information
micha committed Mar 8, 2011
1 parent 1a21c0d commit fea541b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion resty
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,10 @@ function resty() {
[ "$i" = "-Z" ] || [ "$method" = "HEAD" ] || [ "$method" = "OPTIONS" ] \
&& raw="yes" && continue
[ "$i" = "-W" ] && continue
curlopt[j]="$i" && j=$((j + 1))
echo "curlopt[$j] => '$i'"
curlopt[$j]="$i" && echo "curlopt[$j] == '${curlopt[$j]}'" && j=$((j + 1))
done
echo "curlopt[@] == '${curlopt[@]}'" && return

[ -z "$_resty_host" ] && _resty_host=$(cat "$host" 2>/dev/null)
[ -z "$method" ] && echo "$_resty_host" && return
Expand Down

0 comments on commit fea541b

Please sign in to comment.