summary refs log tree commit
diff options
context:
space:
mode:
authorAdrian Setyadi <a.styd@yahoo.com>2019-10-22 13:29:30 +0700
committerAdrian Setyadi <a.styd@yahoo.com>2019-10-22 13:29:30 +0700
commit8cbb32a8331faa0168a9a5f989e611d838ba2ced (patch)
tree32464579b1ba5aab49a32abc25cbe773fbd3c951
parent4ffc2741ac4e54abe4f12b4c058376d6c7e770ed (diff)
downloadrack-8cbb32a8331faa0168a9a5f989e611d838ba2ced.tar.gz
Simplify joining 2 strings
-rw-r--r--lib/rack/auth/digest/nonce.rb4
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?