Skip to content

Commit

Permalink
Fixed issue: Unable to log in to MSSQL when updating from 2.05 or older
Browse files Browse the repository at this point in the history
  • Loading branch information
c-schmitz committed Mar 15, 2018
1 parent f16a7d5 commit a2accbe
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions application/models/User.php
Expand Up @@ -532,18 +532,4 @@ public function search()
)
));
}

/** @inheritdoc */
public function beforeSave()
{
switch(Yii::app()->db->getDriverName()) {
case 'sqlsrv':
case 'mssql': // Deprecated ?
$this->one_time_pw = new CDbExpression("CONVERT(VARBINARY(MAX), :one_time_pw)", array(':one_time_pw' => $this->one_time_pw));
default:
// Nothing to do
}
return parent::beforeSave();
}

}

0 comments on commit a2accbe

Please sign in to comment.