瀏覽代碼

Make Predis\Client::setProfile() private.

Daniele Alessandri 14 年之前
父節點
當前提交
b202e6cae7
共有 2 個文件被更改,包括 3 次插入1 次删除
  1. 2 0
      CHANGELOG
  2. 1 1
      lib/Predis.php

+ 2 - 0
CHANGELOG

@@ -11,6 +11,8 @@ v0.7.0 (2010-xx-xx)
       - Predis\Client::rawCommand()
       - Predis\Client::rawCommand()
         This method was removed due to interface inconsistencies with the 
         This method was removed due to interface inconsistencies with the 
         underlying connection class used internally by the client instance.
         underlying connection class used internally by the client instance.
+      - Predis\Client::setProfile()
+        This method is no more part of the public API and has been made private.
 
 
   * The Predis\MultiBulkCommand class has been merged into Predis\Command and 
   * The Predis\MultiBulkCommand class has been merged into Predis\Command and 
     thus removed. If you have code that extends Predis\MultiBulkCommand but 
     thus removed. If you have code that extends Predis\MultiBulkCommand but 

+ 1 - 1
lib/Predis.php

@@ -132,7 +132,7 @@ class Client {
         $this->_connection = $connection;
         $this->_connection = $connection;
     }
     }
 
 
-    public function setProfile($serverProfile) {
+    private function setProfile($serverProfile) {
         if (!($serverProfile instanceof RedisServerProfile || is_string($serverProfile))) {
         if (!($serverProfile instanceof RedisServerProfile || is_string($serverProfile))) {
             throw new \InvalidArgumentException(
             throw new \InvalidArgumentException(
                 "Invalid type for server profile, \Predis\RedisServerProfile or string expected"
                 "Invalid type for server profile, \Predis\RedisServerProfile or string expected"