From 1fe0a1b5ebebb1372968606b85ce08b93bc145c8 Mon Sep 17 00:00:00 2001 From: Aaron Patterson Date: Mon, 21 Sep 2015 15:05:00 -0700 Subject: remove html_types set Now that `all` has it's own object, we don't need the html_types Set. --- actionpack/lib/action_dispatch/http/mime_type.rb | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'actionpack/lib') diff --git a/actionpack/lib/action_dispatch/http/mime_type.rb b/actionpack/lib/action_dispatch/http/mime_type.rb index 553f19b5bc..7f0b525f6f 100644 --- a/actionpack/lib/action_dispatch/http/mime_type.rb +++ b/actionpack/lib/action_dispatch/http/mime_type.rb @@ -1,4 +1,3 @@ -require 'set' require 'singleton' require 'active_support/core_ext/module/attribute_accessors' require 'active_support/core_ext/string/starts_ends_with' @@ -95,9 +94,6 @@ to: # end # end class Type - @@html_types = Set.new [:html, :all] - cattr_reader :html_types - attr_reader :symbol @register_callbacks = [] @@ -301,7 +297,7 @@ to: end def ref - to_sym || to_s + symbol || to_s end def ===(list) @@ -328,7 +324,7 @@ to: end def html? - @@html_types.include?(to_sym) || @string =~ /html/ + symbol == :html || @string =~ /html/ end def all?; false; end -- cgit v1.2.3