mirror of
https://github.com/samsonjs/http-cookie.git
synced 2026-03-25 08:55:53 +00:00
Fix Hash.try_convert.
This commit is contained in:
parent
94d28bdfbb
commit
03627aa42a
1 changed files with 1 additions and 1 deletions
|
|
@ -16,7 +16,7 @@ class Hash
|
|||
class << self
|
||||
def try_convert(object)
|
||||
if object.is_a?(Hash) ||
|
||||
(object.respond_to?(:to_h) && (object = object.to_str).is_a?(Hash))
|
||||
(object.respond_to?(:to_hash) && (object = object.to_hash).is_a?(Hash))
|
||||
object
|
||||
else
|
||||
nil
|
||||
|
|
|
|||
Loading…
Reference in a new issue