diff options
author | Guillermo Iguaran <guilleiguaran@gmail.com> | 2012-10-31 10:01:39 -0500 |
---|---|---|
committer | Guillermo Iguaran <guilleiguaran@gmail.com> | 2012-10-31 10:01:39 -0500 |
commit | 4b20cd9c663a417353e4d0388189af71cc642fca (patch) | |
tree | 3ccb842f538cca13fcd24661e68b68a6728101f0 /actionpack/lib | |
parent | 9fdf606954a61658b166b48d795313c33957b2c1 (diff) | |
download | rails-4b20cd9c663a417353e4d0388189af71cc642fca.tar.gz rails-4b20cd9c663a417353e4d0388189af71cc642fca.tar.bz2 rails-4b20cd9c663a417353e4d0388189af71cc642fca.zip |
Revert "if format is unknown NullMimeTypeObject is returned"
This reverts commit a8560fa361958b33d76e4468eb5c07d82a20196e.
Diffstat (limited to 'actionpack/lib')
-rw-r--r-- | actionpack/lib/action_dispatch/http/mime_type.rb | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/actionpack/lib/action_dispatch/http/mime_type.rb b/actionpack/lib/action_dispatch/http/mime_type.rb index 5ee6f2056e..3d560518e1 100644 --- a/actionpack/lib/action_dispatch/http/mime_type.rb +++ b/actionpack/lib/action_dispatch/http/mime_type.rb @@ -153,7 +153,7 @@ module Mime end def lookup_by_extension(extension) - EXTENSION_LOOKUP[extension.to_s] || NullMimeTypeObject.new + EXTENSION_LOOKUP[extension.to_s] end # Registers an alias that's not used on mime type lookup, but can be referenced directly. Especially useful for @@ -301,17 +301,6 @@ module Mime method.to_s.ends_with? '?' end end - - class NullMimeTypeObject - private - def method_missing(method, *args) - if method.to_s.ends_with? '?' - false - else - super - end - end - end end require 'action_dispatch/http/mime_types' |