Skip to content

Commit

Permalink
Merge pull request discourse#503 from nverba/patch-1
Browse files Browse the repository at this point in the history
Update mini_profiler.rb
  • Loading branch information
SamSaffron committed Mar 20, 2013
2 parents 204759a + 9a1fb90 commit c125f5d
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions config/initializers/mini_profiler.rb
@@ -1,8 +1,7 @@
# If Mini Profiler is included via gem
if defined?(Rack::MiniProfiler)

Rack::MiniProfiler.config.storage_options = YAML.load(ERB.new(File.new("#{Rails.root}/config/redis.yml").read).result)[Rails.env].symbolize_keys
Rack::MiniProfiler.config.storage = Rack::MiniProfiler::RedisStore
Rack::MiniProfiler::RedisStore.new(:connection => DiscourseRedis.new)

# For our app, let's just show mini profiler always, polling is chatty so nuke that
Rack::MiniProfiler.config.pre_authorize_cb = lambda do |env|
Expand Down

0 comments on commit c125f5d

Please sign in to comment.