diff options
author | Semyon Pupkov <mail@semyonpupkov.com> | 2017-11-13 14:48:29 +0500 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2019-08-04 09:19:30 +0900 |
commit | 4173258fd0413c49ef07d54bc9654bba7e497e89 (patch) | |
tree | 74f0024198404b5b455eaed5b0c39d5a9076e468 /lib/cgi/core.rb | |
parent | 8e7df4bbf991b9d605784225db0750bbfe681f23 (diff) |
change call CGI methods from :: to .
Closes: https://github.com/ruby/ruby/pull/1749
Diffstat (limited to 'lib/cgi/core.rb')
-rw-r--r-- | lib/cgi/core.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/cgi/core.rb b/lib/cgi/core.rb index c45f9b3a9e..ac0d2d3cb3 100644 --- a/lib/cgi/core.rb +++ b/lib/cgi/core.rb @@ -375,14 +375,14 @@ class CGI # Parse an HTTP query string into a hash of key=>value pairs. # - # params = CGI::parse("query_string") + # params = CGI.parse("query_string") # # {"name1" => ["value1", "value2", ...], # # "name2" => ["value1", "value2", ...], ... } # - def CGI::parse(query) + def self.parse(query) params = {} query.split(/[&;]/).each do |pairs| - key, value = pairs.split('=',2).collect{|v| CGI::unescape(v) } + key, value = pairs.split('=',2).collect{|v| CGI.unescape(v) } next unless key @@ -656,7 +656,7 @@ class CGI @params = read_multipart(boundary, Integer(env_table['CONTENT_LENGTH'])) else @multipart = false - @params = CGI::parse( + @params = CGI.parse( case env_table['REQUEST_METHOD'] when "GET", "HEAD" if defined?(MOD_RUBY) @@ -686,7 +686,7 @@ class CGI end end - @cookies = CGI::Cookie::parse((env_table['HTTP_COOKIE'] or env_table['COOKIE'])) + @cookies = CGI::Cookie.parse((env_table['HTTP_COOKIE'] or env_table['COOKIE'])) end private :initialize_query |