Ruby 1.9.1 Fixes

Some more fixes to deal with Ruby 1.9.1.
This commit is contained in:
Jacques Distler 2009-12-02 12:46:15 -06:00
parent 063a8ca5a7
commit f7044ecbb4
4 changed files with 11 additions and 6 deletions

View file

@ -11,7 +11,7 @@ module ActionView
session[:form_keys][Digest::SHA1.hexdigest(form_key)] = [Time.now, 0]
if session[:form_keys].length > 30
first = session[:form_keys].values.sort { |a,b| a[0] <=> b[0] } [0]
session[:form_keys].delete(session[:form_keys].index(first))
session[:form_keys].delete(session[:form_keys].key(first))
end
out << domEnkode(form_key)
end