Merge remote-tracking branch 'upstream/4.11' into 4.12

This commit is contained in:
Daniel Hensby 2022-11-11 13:25:54 +00:00
commit c49abf0fcc
No known key found for this signature in database
GPG Key ID: D8DEBC4C8E7BC8B9
2 changed files with 3 additions and 1 deletions

View File

@ -162,7 +162,7 @@ class StandardRelatedDataService implements RelatedDataService
$tableName = $this->dataObjectSchema->tableName($candidateClass); $tableName = $this->dataObjectSchema->tableName($candidateClass);
break; break;
} }
$candidateClass = get_parent_class($class ?? ''); $candidateClass = get_parent_class($candidateClass ?? '');
} }
return $tableName; return $tableName;
} }

View File

@ -7,6 +7,7 @@ use SilverStripe\Security\Member;
use SilverStripe\Security\PasswordEncryptor; use SilverStripe\Security\PasswordEncryptor;
use SilverStripe\Security\Permission; use SilverStripe\Security\Permission;
use SilverStripe\Security\DefaultAdminService; use SilverStripe\Security\DefaultAdminService;
use SilverStripe\Security\Security;
class SecurityDefaultAdminTest extends SapphireTest class SecurityDefaultAdminTest extends SapphireTest
{ {
@ -35,6 +36,7 @@ class SecurityDefaultAdminTest extends SapphireTest
$this->defaultUsername = null; $this->defaultUsername = null;
$this->defaultPassword = null; $this->defaultPassword = null;
} }
Security::config()->set('password_encryption_algorithm', 'blowfish');
DefaultAdminService::setDefaultAdmin('admin', 'password'); DefaultAdminService::setDefaultAdmin('admin', 'password');
Permission::reset(); Permission::reset();
} }