perf(admin): fix N+1 on procedures zones on every admin page
This commit is contained in:
parent
15e78e94f3
commit
e1102ed993
1 changed files with 1 additions and 1 deletions
|
@ -139,7 +139,7 @@ class Administrateur < ApplicationRecord
|
|||
end
|
||||
|
||||
def zones
|
||||
procedures.joins(:zones).flat_map(&:zones).uniq
|
||||
procedures.includes(:zones).flat_map(&:zones).uniq
|
||||
end
|
||||
|
||||
# required to display feature flags field in manager
|
||||
|
|
Loading…
Reference in a new issue