From 01c269a912261929a30bb32035daabc2e534488b Mon Sep 17 00:00:00 2001 From: Paul Klimov Date: Fri, 22 Nov 2013 13:37:43 +0200 Subject: [PATCH] Redundant typecast removed from yii\sphinx\ActiveRecord::create() --- extensions/sphinx/ActiveRecord.php | 3 --- extensions/sphinx/Connection.php | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/extensions/sphinx/ActiveRecord.php b/extensions/sphinx/ActiveRecord.php index 95106a6..e62620c 100644 --- a/extensions/sphinx/ActiveRecord.php +++ b/extensions/sphinx/ActiveRecord.php @@ -1297,9 +1297,6 @@ class ActiveRecord extends Model $column = $columns[$name]; if ($column->isMva) { $value = explode(',', $value); - $value = array_map([$column, 'typecast'], $value); - } else { - $value = $column->typecast($value); } $record->_attributes[$name] = $value; } else { diff --git a/extensions/sphinx/Connection.php b/extensions/sphinx/Connection.php index dbbe27a..a43b0c2 100644 --- a/extensions/sphinx/Connection.php +++ b/extensions/sphinx/Connection.php @@ -124,6 +124,6 @@ class Connection extends \yii\db\Connection */ public function getLastInsertID($sequenceName = '') { - throw new NotSupportedException('"' . $this->className() . '::getLastInsertID" is not supported.'); + throw new NotSupportedException('"' . __METHOD__ . '" is not supported.'); } } \ No newline at end of file