newrelic: refactor error logging.

* Factor out New Relic logging to DanbooruLogger class.
* Log all exceptions to New Relic, not just statement timeouts.
This commit is contained in:
evazion
2019-08-08 22:16:39 -05:00
parent 35dfc704bc
commit 9a6add9730
9 changed files with 27 additions and 37 deletions

View File

@@ -72,7 +72,7 @@ module Moderator
user.update(blacklisted_tags: repl.join("\n"))
end
rescue Exception => e
NewRelic::Agent.notice_error(e)
DanbooruLogger.log(e)
end
end
end