Explorar el Código

Reduce lines of code.

Daniele Alessandri hace 14 años
padre
commit
f1488534b6
Se han modificado 1 ficheros con 1 adiciones y 5 borrados
  1. 1 5
      lib/Predis.php

+ 1 - 5
lib/Predis.php

@@ -119,11 +119,7 @@ class Client {
                 "Invalid connection alias: '$connectionAlias'"
             );
         }
-
-        $newClient = new Client();
-        $newClient->setupClient($this->_options);
-        $newClient->setConnection($connection);
-        return $newClient;
+        return new Client($connection, $this->_options);
     }
 
     public function connect() {