mirror of
https://github.com/predis/predis.git
synced 2026-09-05 07:16:44 +00:00
Remove a useless check for the payload length.
This commit is contained in:
+1
-4
@@ -688,16 +688,13 @@ class ResponseReader {
|
||||
}
|
||||
|
||||
$prefix = $header[0];
|
||||
$payload = strlen($header) > 1 ? substr($header, 1) : '';
|
||||
|
||||
if (!isset($this->_prefixHandlers[$prefix])) {
|
||||
Shared\Utils::onCommunicationException(new MalformedServerResponse(
|
||||
$connection, "Unknown prefix '$prefix'"
|
||||
));
|
||||
}
|
||||
|
||||
$handler = $this->_prefixHandlers[$prefix];
|
||||
return $handler->handle($connection, $payload);
|
||||
return $handler->handle($connection, substr($header, 1));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user