dossier: cache the dossier value

This commit is contained in:
Pierre de La Morinerie 2018-09-04 17:47:34 +02:00
parent 63472f00e6
commit 5cfb200417

View file

@ -185,7 +185,7 @@ module NewUser
end
def dossier
Dossier.find(params[:id] || params[:dossier_id])
@dossier ||= Dossier.find(params[:id] || params[:dossier_id])
end
def dossier_with_champs