Skip to content

Instantly share code, notes, and snippets.

@mrrooijen
Forked from mateomurphy/dragonfly filename fix
Created September 5, 2010 21:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mrrooijen/566352 to your computer and use it in GitHub Desktop.
Save mrrooijen/566352 to your computer and use it in GitHub Desktop.
module Dragonfly
module Endpoint
def success_headers(job)
{
"Content-Type" => job.app.resolve_mime_type(job.result),
"Content-Length" => job.size.to_s,
"Content-Disposition" => "filename=#{job.name}"
}.merge(cache_headers(job))
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment