class Object

Public Instance Methods

load(klass_or_module) click to toggle source
# File lib/dpl/support/aws_sdk_patch.rb, line 11
def load(klass_or_module)
  @loaded << klass_or_module
  klass_or_module.constants.each do |const_name|
    next if const_name == :Tms

    path = klass_or_module.autoload?(const_name)
    begin
      require(path) if path
      const = klass_or_module.const_get(const_name)
      self.load(const) if const.is_a?(Module) && !@loaded.include?(const)
    rescue LoadError
    end
  end
  self
end
sign(str) click to toggle source
# File lib/dpl/support/gstore_patch.rb, line 4
def sign(str)
  digest = OpenSSL::Digest.new('sha1') # use undeprecated constant
  Base64.encode64(OpenSSL::HMAC.digest(digest, @secret_key, str)).gsub("\n", '')
end