diff --git a/lib/PasswordPolicyConfig.php b/lib/PasswordPolicyConfig.php index e13f87a1..51ff5ec1 100644 --- a/lib/PasswordPolicyConfig.php +++ b/lib/PasswordPolicyConfig.php @@ -53,8 +53,7 @@ public function __construct(IConfig $config) { * @return int */ public function getMinLength(): int { - $minLength = $this->config->getAppValue('password_policy', 'minLength', '8'); - return (int)$minLength; + return (int)$this->config->getAppValue('password_policy', 'minLength', '10'); } /** diff --git a/tests/lib/PasswordPolicyConfigTest.php b/tests/lib/PasswordPolicyConfigTest.php index 2a84f5cb..a9249640 100644 --- a/tests/lib/PasswordPolicyConfigTest.php +++ b/tests/lib/PasswordPolicyConfigTest.php @@ -45,7 +45,7 @@ public function testGetMinLength() { $expected = 42; $this->config->expects($this->once())->method('getAppValue') - ->with('password_policy', 'minLength', '8') + ->with('password_policy', 'minLength', '10') ->willReturn($appConfigValue); $this->assertSame($expected,