BigW Consortium Gitlab

Commit c51c9019 by Kamil Trzcinski

Return the external issue tracker even if it's null

This solves the problem with caching the nil value with instance variable. Without this the every time we ask for external_issue_tracker we built AR and potentially do SQL query
parent 94031420
......@@ -508,6 +508,7 @@ class Project < ActiveRecord::Base
end
def external_issue_tracker
return @external_issue_tracker if defined?(@external_issue_tracker)
@external_issue_tracker ||=
services.issue_trackers.active.without_defaults.first
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment