mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
Authentication for test wasn't working. (merged from branches/2.2.0@45907, r45823)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/trunk@46114 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
8f712a3392
commit
425714a281
@ -491,8 +491,10 @@ class Security extends Controller {
|
||||
&& !empty(self::$default_username) && !empty(self::$default_password)) {
|
||||
$member = self::findAnAdministrator();
|
||||
} else {
|
||||
$member = DataObject::get_one("Member",
|
||||
"Email = '$SQL_email' And Password = '$SQL_password'");
|
||||
$member = DataObject::get_one("Member", "Email = '$SQL_email' AND Password IS NOT NULL");
|
||||
if($member && ($member->checkPassword($RAW_password) == false)) {
|
||||
$member = null;
|
||||
}
|
||||
}
|
||||
|
||||
return $member;
|
||||
|
Loading…
x
Reference in New Issue
Block a user