瀏覽代碼

Bugfix: return an empty string instead of null when the data length of a bulk reply is 0.

Daniele Alessandri 15 年之前
父節點
當前提交
55c40afcd8
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      lib/Predis.php

+ 1 - 1
lib/Predis.php

@@ -312,8 +312,8 @@ class Response {
                     return $value;
                 }
                 else if ($dataLength == 0) {
-                    // TODO: I just have a doubt here...
                     fread($socket, 2);
+                    return '';
                 }
 
                 return null;