Revert 8606fb4eba and 40a60efd28 since the original problem had already been solved by handling FastImage::UnknownImageType in 0d806277f9. See #660.

This commit is contained in:
Ben Hollis 2013-01-03 22:55:10 -08:00
parent 55a674853f
commit 15ca8db58d

View file

@ -30,11 +30,7 @@ module Middleman
# @param [Hash] params
# @return [String]
def image_tag(path, params={})
params[:supported_extensions] ||= %w(.png .jpg .jpeg .bmp .gif)
if !params.has_key?(:width) && !params.has_key?(:height) && !path.include?("://") &&
params[:supported_extensions].include?(File.extname(path).downcase)
if !params.has_key?(:width) && !params.has_key?(:height) && !path.include?("://")
params[:alt] ||= ""
real_path = path
@ -53,8 +49,6 @@ module Middleman
end
end
end
params = params.delete_if {|key| key == :supported_extensions }
super(path, params)
end