Skip to content

Commit

Permalink
Ensure expires_in and created_at timestamps aren't nil when attemptin…
Browse files Browse the repository at this point in the history
…g to upgrade cache
  • Loading branch information
josh committed Oct 10, 2012
1 parent bf24ba9 commit b21f24d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion activesupport/lib/active_support/cache.rb
Original file line number Diff line number Diff line change
Expand Up @@ -644,7 +644,7 @@ def convert_version_3_entry!
@c = @compressed
remove_instance_variable(:@compressed)
end
if defined?(@expires_in) && defined?(@created_at)
if defined?(@expires_in) && defined?(@created_at) && @expires_in && @created_at
@x = (@created_at + @expires_in).to_i
remove_instance_variable(:@created_at)
remove_instance_variable(:@expires_in)
Expand Down

0 comments on commit b21f24d

Please sign in to comment.