From e1dbaafefc635fe3066b3d4f85ddb6fcec29229e Mon Sep 17 00:00:00 2001
From: gloas <gloas@afi-sa.fr>
Date: Thu, 31 May 2018 14:18:14 +0200
Subject: [PATCH] dev #75068 fix rt comments

---
 application/modules/opac/controllers/RechercheController.php | 2 +-
 tests/scenarios/SearchResult/SearchResultTest.php            | 2 --
 2 files changed, 1 insertion(+), 3 deletions(-)

diff --git a/application/modules/opac/controllers/RechercheController.php b/application/modules/opac/controllers/RechercheController.php
index de66e8fed33..d13becdc225 100644
--- a/application/modules/opac/controllers/RechercheController.php
+++ b/application/modules/opac/controllers/RechercheController.php
@@ -177,7 +177,7 @@ class RechercheController extends ZendAfi_Controller_Action {
       $instance = Class_CodifThesaurus::findFirstBy(['code' => $code,
                                                      'libelle' => $value]);
       if($instance)
-         $facets[Class_CodifThesaurus::CODE_FACETTE . $instance->getIdThesaurus()] = 1;
+        $facets[$instance->getFacetteIndex()] = 1;
     }
 
     return array_filter($facets);
diff --git a/tests/scenarios/SearchResult/SearchResultTest.php b/tests/scenarios/SearchResult/SearchResultTest.php
index 9535425fb09..afeaef31af2 100644
--- a/tests/scenarios/SearchResult/SearchResultTest.php
+++ b/tests/scenarios/SearchResult/SearchResultTest.php
@@ -272,6 +272,4 @@ class SearchResultWithDynamicFacetTest extends AbstractControllerTestCase {
     $this->dispatch('/opac/recherche/simple/rech_HDOCU/SIFI', true);
     $this->assertRedirectTo('/recherche/simple/multifacets/HDOCU0001');
   }
-
-
 }
\ No newline at end of file
-- 
GitLab