diff options
author | Rafael França <rafael@franca.dev> | 2019-10-28 22:07:42 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-28 22:07:42 -0400 |
commit | 92cf26d84d0ada0d9529df5306a280d298669777 (patch) | |
tree | 560ba010fa441e4679cc40de681491e4327ed256 | |
parent | 57d7ff00956bd82937f5e9cdae615f7f70548cfa (diff) | |
parent | 8cbb32a8331faa0168a9a5f989e611d838ba2ced (diff) | |
download | rack-92cf26d84d0ada0d9529df5306a280d298669777.tar.gz |
Merge pull request #1405 from styd/simplify-joining-string
Simplify joining 2 strings
-rw-r--r-- | lib/rack/auth/digest/nonce.rb | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/rack/auth/digest/nonce.rb b/lib/rack/auth/digest/nonce.rb index 6c1f28a3..089bb6f4 100644 --- a/lib/rack/auth/digest/nonce.rb +++ b/lib/rack/auth/digest/nonce.rb @@ -28,11 +28,11 @@ module Rack end def to_s - [([ @timestamp, digest ] * ' ')].pack("m*").strip + ["#{@timestamp} #{digest}"].pack("m*").strip end def digest - ::Digest::MD5.hexdigest([ @timestamp, self.class.private_key ] * ':') + ::Digest::MD5.hexdigest("#{@timestamp}:#{self.class.private_key}") end def valid? |