From 0223eabccef67348bd011aa8c390f708ee80bfd8 Mon Sep 17 00:00:00 2001 From: Paul Chavard Date: Wed, 27 Jan 2021 18:45:32 +0100 Subject: [PATCH] fix annotations n+1 --- app/graphql/types/dossier_type.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/graphql/types/dossier_type.rb b/app/graphql/types/dossier_type.rb index 55e8716f4..5f06dce75 100644 --- a/app/graphql/types/dossier_type.rb +++ b/app/graphql/types/dossier_type.rb @@ -82,7 +82,7 @@ module Types end def annotations - Loaders::Association.for(object.class, :champs_private).load(object) + Loaders::Association.for(object.class, champs_private: [:type_de_champ]).load(object) end def pdf