mirror of
https://github.com/discourse/discourse.git
synced 2024-11-25 18:30:26 -06:00
cut out an exception
This commit is contained in:
parent
157b118559
commit
9364194f36
@ -22,7 +22,8 @@ class ApplicationRequest < ActiveRecord::Base
|
||||
def self.increment!(type, opts=nil)
|
||||
key = redis_key(type)
|
||||
val = $redis.incr(key).to_i
|
||||
$redis.expire key, 3.days
|
||||
# 3.days, see: https://github.com/rails/rails/issues/21296
|
||||
$redis.expire(key, 259200)
|
||||
|
||||
autoflush = (opts && opts[:autoflush]) || self.autoflush
|
||||
if autoflush > 0 && val >= autoflush
|
||||
|
Loading…
Reference in New Issue
Block a user