1
0
Fork 0
mirror of https://github.com/middleman/middleman.git synced 2022-11-09 12:20:27 -05:00

Merge pull request #1763 from iiska/fix-gzip-log-output

Fix gzip extension status output
This commit is contained in:
Thomas Reynolds 2016-01-19 09:45:47 -08:00
commit c2999786ee

View file

@ -64,10 +64,10 @@ class Middleman::Extensions::Gzip < ::Middleman::Extension
total_savings += (old_size - new_size)
size_change_word = (old_size - new_size) > 0 ? 'smaller' : 'larger'
builder.trigger :gzip, "#{output_filename} (#{NumberHelpers.new.number_to_human_size((old_size - new_size).abs)} #{size_change_word})"
builder.trigger :created, "#{output_filename} (#{NumberHelpers.new.number_to_human_size((old_size - new_size).abs)} #{size_change_word})"
end
builder.trigger :gzip, "Total gzip savings: #{NumberHelpers.new.number_to_human_size(total_savings)}"
builder.trigger :gzip, '', "Total gzip savings: #{NumberHelpers.new.number_to_human_size(total_savings)}"
I18n.locale = old_locale
end