Skip to content

Commit e2ecf81

Browse files
committed
Do not #to_h redirector options
1 parent 5dc27c4 commit e2ecf81

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

lib/http/redirector.rb

+1-3
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,10 @@ class EndlessRedirectError < TooManyRedirectsError; end
3232
# @return [Fixnum]
3333
attr_reader :max_hops
3434

35-
# @param [#to_h] opts
35+
# @param [Hash] opts
3636
# @option opts [Boolean] :strict (true) redirector hops policy
3737
# @option opts [#to_i] :max_hops (5) maximum allowed amount of hops
3838
def initialize(options = {})
39-
options = options.to_h
40-
4139
@strict = options.fetch(:strict, true)
4240
@max_hops = options.fetch(:max_hops, 5).to_i
4341
end

0 commit comments

Comments
 (0)