Show
Ignore:
Timestamp:
09/23/2007 16:44:10 (14 months ago)
Author:
zimbatm
Message:

Gained 10 chars by applying the same technique as on changeset [116].
Only, Array#* apparently also flatten the array!

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/lib/camping-unabridged.rb

    r204 r209  
    446446    # alter the way Camping builds HTTP headers, consider overriding this method. 
    447447    def to_s 
    448       a=[] 
    449       @headers.map{|k,v|[*v].map{|x|a<<"#{k}: #{x}"}} 
    450       "Status: #{@status}#{Z+a*Z+Z*2+@body}" 
     448      "Status: #{@status}#{Z+@headers.map{|k,v|[*v].map{|x|[k,v]*": "}}*Z+Z*2}#{@body}" 
    451449    end 
    452450