mirror of
https://github.com/github/rails.git
synced 2026-04-26 03:00:59 -04:00
Use OpenSSL::Digest.const(...).new instead of OpenSSL::Digest::Digest.new(...)
This commit is contained in:
@@ -53,7 +53,7 @@ module ActiveSupport
|
||||
|
||||
def generate_digest(data)
|
||||
require 'openssl' unless defined?(OpenSSL)
|
||||
OpenSSL::HMAC.hexdigest(OpenSSL::Digest::Digest.new(@digest), @secret, data)
|
||||
OpenSSL::HMAC.hexdigest(OpenSSL::Digest.const_get(@digest).new, @secret, data)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user