Эх сурвалжийг харах

Remove a useless method from the cluster option class.

Daniele Alessandri 14 жил өмнө
parent
commit
b087b9814d

+ 1 - 5
lib/Predis/Options/ClientCluster.php

@@ -17,16 +17,12 @@ class ClientCluster extends Option {
 
     public function validate($value) {
         if (is_callable($value)) {
-            return $this->initializeFromCallable($value);
+            return $this->checkInstance(call_user_func($value));
         }
         $initializer = $this->getInitializer($value);
         return $this->checkInstance($initializer());
     }
 
-    protected function initializeFromCallable($callable) {
-        return $this->checkInstance(call_user_func($callable));
-    }
-
     protected function getInitializer($fqnOrType) {
         switch ($fqnOrType) {
             case 'predis':