Browse Source

fixed db exception according to signature change

tags/2.0.0-beta
Carsten Brandt 12 years ago
parent
commit
fd5e6ccfed
  1. 1
      yii/db/redis/ActiveRecord.php
  2. 4
      yii/db/redis/Connection.php

1
yii/db/redis/ActiveRecord.php

@ -14,7 +14,6 @@ use yii\base\InvalidConfigException;
use yii\base\InvalidParamException;
use yii\base\NotSupportedException;
use yii\base\UnknownMethodException;
use yii\db\Exception;
use yii\db\TableSchema;
/**

4
yii/db/redis/Connection.php

@ -256,7 +256,7 @@ class Connection extends Component
} else {
\Yii::error("Failed to open DB connection ({$this->dsn}): " . $errorNumber . ' - ' . $errorDescription, __CLASS__);
$message = YII_DEBUG ? 'Failed to open DB connection: ' . $errorNumber . ' - ' . $errorDescription : 'Failed to open DB connection.';
throw new Exception($message, (int)$errorNumber, $errorDescription);
throw new Exception($message, $errorDescription, (int)$errorNumber);
}
}
}
@ -355,7 +355,7 @@ class Connection extends Component
*
* See [redis protocol description](http://redis.io/topics/protocol)
* for details on the mentioned reply types.
* @trows CException for commands that return [error reply](http://redis.io/topics/protocol#error-reply).
* @trows Exception for commands that return [error reply](http://redis.io/topics/protocol#error-reply).
*/
public function executeCommand($name, $params=array())
{

Loading…
Cancel
Save