Skip to content
Browse files

Merge pull request #335 from ender672/cookie

Use String#<< over +=
  • Loading branch information...
2 parents 4c58e4d + 4ed9e61 commit 6c997a323d53cc763217f2854ca6204803cb440b @tenderlove tenderlove committed
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/rack/session/cookie.rb
View
2 lib/rack/session/cookie.rb
@@ -136,7 +136,7 @@ def set_session(env, session_id, session, options)
session_data = coder.encode(session)
if @secrets.first
- session_data = "#{session_data}--#{generate_hmac(session_data, @secrets.first)}"
+ session_data << "--#{generate_hmac(session_data, @secrets.first)}"
end
if session_data.size > (4096 - @key.size)

0 comments on commit 6c997a3

Please sign in to comment.
Something went wrong with that request. Please try again.