소스 검색

Slightly improved the internals of Command::getArgument and Command::getArguments.

Daniele Alessandri 15 년 전
부모
커밋
b777daa535
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      lib/Predis.php

+ 2 - 2
lib/Predis.php

@@ -332,11 +332,11 @@ abstract class Command {
     }
 
     protected function getArguments() {
-        return $this->_arguments !== null ? $this->_arguments : array();
+        return isset($this->_arguments) ? $this->_arguments : array();
     }
 
     public function getArgument($index = 0) {
-        return $this->_arguments !== null ? $this->_arguments[$index] : null;
+        return isset($this->_arguments[$index]) ? $this->_arguments[$index] : null;
     }
 
     public function parseResponse($data) {