소스 검색

Fix some more namespacing issues.

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

+ 5 - 2
lib/Predis/Protocols/TextProtocol.php

@@ -3,6 +3,9 @@
 namespace Predis\Protocols;
 
 use Predis\ICommand;
+use Predis\ResponseError;
+use Predis\ResponseQueued;
+use Predis\ServerException;
 use Predis\CommunicationException;
 use Predis\Network\IConnectionComposable;
 use Predis\Iterators\MultiBulkResponseSimple;
@@ -76,9 +79,9 @@ class TextProtocol implements IRedisProtocol {
             case '-':    // error
                 $errorMessage = substr($payload, 4);
                 if ($this->_throwErrors) {
-                    throw new \Predis\ServerException($errorMessage);
+                    throw new ServerException($errorMessage);
                 }
-                return new \Predis\ResponseError($errorMessage);
+                return new ResponseError($errorMessage);
 
             default:
                 throw new CommunicationException(