Module: SendFile

Defined in:
lib/send_file.rb

Instance Method Summary collapse

Instance Method Details

#send_file(path) ⇒ Object



2
3
4
5
6
7
# File 'lib/send_file.rb', line 2

def send_file(path)
  file = Rack::File.new(nil)
  file.path = path

  return halt(file.serving(env))
end