From e610e7003467bdc7b8bb74ed0344a6e312e233cf Mon Sep 17 00:00:00 2001
From: Demian Katz <demian.katz@villanova.edu>
Date: Wed, 24 Apr 2013 15:57:31 -0400
Subject: [PATCH] Simplified translation.

---
 module/VuFind/src/VuFind/Search/Base/Params.php  | 4 +---
 module/VuFind/src/VuFind/Search/Base/Results.php | 4 +---
 2 files changed, 2 insertions(+), 6 deletions(-)

diff --git a/module/VuFind/src/VuFind/Search/Base/Params.php b/module/VuFind/src/VuFind/Search/Base/Params.php
index 0794a429c03..22673a553ba 100644
--- a/module/VuFind/src/VuFind/Search/Base/Params.php
+++ b/module/VuFind/src/VuFind/Search/Base/Params.php
@@ -1325,9 +1325,7 @@ class Params implements ServiceLocatorAwareInterface
      */
     public function translate($msg)
     {
-        return $this->getServiceLocator()->has('VuFind\Translator')
-            ? $this->getServiceLocator()->get('VuFind\Translator')->translate($msg)
-            : $msg;
+        return $this->getOptions()->translate($msg);
     }
 
     /**
diff --git a/module/VuFind/src/VuFind/Search/Base/Results.php b/module/VuFind/src/VuFind/Search/Base/Results.php
index 464ba80e243..5967989647a 100644
--- a/module/VuFind/src/VuFind/Search/Base/Results.php
+++ b/module/VuFind/src/VuFind/Search/Base/Results.php
@@ -590,8 +590,6 @@ abstract class Results implements ServiceLocatorAwareInterface
      */
     public function translate($msg)
     {
-        return $this->getServiceLocator()->has('VuFind\Translator')
-            ? $this->getServiceLocator()->get('VuFind\Translator')->translate($msg)
-            : $msg;
+        return $this->getOptions()->translate($msg);
     }
 }
\ No newline at end of file
-- 
GitLab