Skip to content

Commit

Permalink
Merge pull request #494 from petergoldstein/feature/explicit_to_i_on_ttl
Browse files Browse the repository at this point in the history
Add an explicit to_i on the ttl value
  • Loading branch information
petergoldstein committed Oct 12, 2014
2 parents 2be9844 + 9b0cf6d commit 13c4ab4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/dalli/server.rb
Expand Up @@ -471,9 +471,9 @@ def guard_max_value(key, value)
def sanitize_ttl(ttl)
if ttl > MAX_ACCEPTABLE_EXPIRATION_INTERVAL
Dalli.logger.debug "Expiration interval too long for Memcached, converting to an expiration timestamp"
Time.now.to_i + ttl
Time.now.to_i + ttl.to_i
else
ttl
ttl.to_i
end
end

Expand Down

0 comments on commit 13c4ab4

Please sign in to comment.