mirror of
https://github.com/discourse/discourse.git
synced 2025-06-04 21:26:02 +08:00
Add an option to not flush redis every time sidekiq.rb is loaded in development
This commit is contained in:
@ -2,7 +2,7 @@ require "#{Rails.root}/lib/discourse_redis"
|
||||
|
||||
$redis = DiscourseRedis.new
|
||||
|
||||
if Rails.env.development?
|
||||
if Rails.env.development? and !ENV['DO_NOT_FLUSH_REDIS']
|
||||
puts "Flushing redis (development mode)"
|
||||
$redis.flushall
|
||||
end
|
||||
|
Reference in New Issue
Block a user