# File lib/parts.rb, line 40 def initialize(boundary, name, io) file_length = io.respond_to?(:length) ? io.length : File.size(io.local_path) @head = build_head(boundary, name, io.original_filename, io.content_type, file_length) @length = @head.length + file_length @io = CompositeReadIO.new(StringIO.new(@head), io, StringIO.new("\r\n")) end