Skip to content

Commit

Permalink
Merge d255955 into 4e9a8d7
Browse files Browse the repository at this point in the history
  • Loading branch information
correalucas committed Sep 5, 2019
2 parents 4e9a8d7 + d255955 commit 048f824
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion lib/axlsx_rails/template_handler.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,14 @@ module Template::Handlers
class AxlsxBuilder

def default_format
Rails.version.to_f >= 5 ? Mime[:xlsx] : Mime::XLSX
case
when Rails.version.to_f >= 6
Mime[:xlsx].symbol
when Rails.version.to_f >= 5
Mime[:xlsx]
else
Mime::XLSX
end
end

def call(template, source = nil)
Expand Down

0 comments on commit 048f824

Please sign in to comment.