mirror of
https://github.com/predis/predis.git
synced 2026-10-09 05:16:32 +00:00
Convert monolithic one-file-lib to a proper PSR-0 file tree
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
<?php
|
||||
|
||||
namespace Predis;
|
||||
|
||||
class ResponseError {
|
||||
public $skipParse = true;
|
||||
private $_message;
|
||||
|
||||
public function __construct($message) {
|
||||
$this->_message = $message;
|
||||
}
|
||||
|
||||
public function __get($property) {
|
||||
if ($property === 'error') {
|
||||
return true;
|
||||
}
|
||||
if ($property === 'message') {
|
||||
return $this->_message;
|
||||
}
|
||||
}
|
||||
|
||||
public function __isset($property) {
|
||||
return $property === 'error';
|
||||
}
|
||||
|
||||
public function __toString() {
|
||||
return $this->_message;
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user