mirror of
https://github.com/KevinMidboe/linguist.git
synced 2025-10-29 17:50:22 +00:00
Don't send blank attachment filename
This commit is contained in:
@@ -68,6 +68,8 @@ module Linguist
|
|||||||
def disposition
|
def disposition
|
||||||
if text? || image?
|
if text? || image?
|
||||||
'inline'
|
'inline'
|
||||||
|
elsif name.nil?
|
||||||
|
"attachment"
|
||||||
else
|
else
|
||||||
"attachment; filename=#{EscapeUtils.escape_url(pathname.basename)}"
|
"attachment; filename=#{EscapeUtils.escape_url(pathname.basename)}"
|
||||||
end
|
end
|
||||||
|
|||||||
Reference in New Issue
Block a user