mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 15:48:43 -05:00
cut out an exception
This commit is contained in:
parent
157b118559
commit
9364194f36
1 changed files with 2 additions and 1 deletions
|
@ -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 a new issue