From 02fd5a29396db507d2ebe572daad432eca3c32db Mon Sep 17 00:00:00 2001 From: Xavier J Date: Thu, 22 Dec 2016 11:55:24 +0100 Subject: [PATCH] Fix tests --- app/controllers/backoffice/dossiers_controller.rb | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/app/controllers/backoffice/dossiers_controller.rb b/app/controllers/backoffice/dossiers_controller.rb index 78644ccdb..3537d6c5e 100644 --- a/app/controllers/backoffice/dossiers_controller.rb +++ b/app/controllers/backoffice/dossiers_controller.rb @@ -19,11 +19,13 @@ class Backoffice::DossiersController < Backoffice::DossiersListController def show create_dossier_facade params[:id] - @champs_private = @facade.champs_private unless @facade.nil? + unless @facade.nil? + @champs_private = @facade.champs_private - @headers_private = @champs_private.inject([]) do |acc, champ| - acc.push(champ) if champ.type_champ == 'header_section' - acc + @headers_private = @champs_private.inject([]) do |acc, champ| + acc.push(champ) if champ.type_champ == 'header_section' + acc + end end end