make sure to log error reports against the master

so that even slave failures get recorded

Change-Id: Idb276e02e0c4ff1f5b3c6ab027669d3f5fcda1b9
Reviewed-on: https://gerrit.instructure.com/15974
Reviewed-by: Brian Palmer <brianp@instructure.com>
Tested-by: Brian Palmer <brianp@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>
This commit is contained in:
Cody Cutrer 2012-12-10 14:32:43 -07:00
parent 66e3a391d7
commit f444db290f
1 changed files with 6 additions and 4 deletions

View File

@ -66,10 +66,12 @@ class ErrorReport < ActiveRecord::Base
end
def create_error_report(opts)
report = ErrorReport.new
report.assign_data(opts)
report.save
report
ActiveRecord::Base::ConnectionSpecification.with_environment(nil) do
report = ErrorReport.new
report.assign_data(opts)
report.save
report
end
end
end