don't try to load airbrake if there is no config for it

This commit is contained in:
Sam
2013-03-11 16:59:07 -07:00
parent 2115c36c84
commit a0bdbe046a
5 changed files with 19 additions and 8 deletions

View File

@@ -12,7 +12,7 @@ if defined?(PhusionPassenger)
if forked
# We're in smart spawning mode.
$redis = DiscourseRedis.new
Discourse::Application.config.cache_store.reconnect# = DiscourseRedis.new_redis_store
Discourse::Application.config.cache_store.reconnect
else
# We're in conservative spawning mode. We don't need to do anything.
end

View File

@@ -0,0 +1,3 @@
if Rails.env.production? && File.exists?(Rails.root + '/config/airbrake.rb')
require 'airbrake'
end