method
new
v4.1.8 -
Show latest stable
- Class:
ActionDispatch::Http::UploadedFile
new(hash)public
No documentation available.
# File actionpack/lib/action_dispatch/http/upload.rb, line 25
def initialize(hash) # :nodoc:
@tempfile = hash[:tempfile]
raise(ArgumentError, ':tempfile is required') unless @tempfile
@original_filename = encode_filename(hash[:filename])
@content_type = hash[:type]
@headers = hash[:head]
end