您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

timeout_fixes.rb 448B

12345678910111213141516171819202122
  1. # frozen_string_literal: true
  2. # http://trac.openidenabled.com/trac/ticket/156
  3. module OpenID
  4. @@timeout_threshold = 20
  5. def self.timeout_threshold
  6. @@timeout_threshold
  7. end
  8. def self.timeout_threshold=(value)
  9. @@timeout_threshold = value
  10. end
  11. class StandardFetcher
  12. def make_http(uri)
  13. http = @proxy.new(uri.host, uri.port)
  14. http.read_timeout = http.open_timeout = OpenID.timeout_threshold
  15. http
  16. end
  17. end
  18. end