diff options
author | Roeland Jago Douma <roeland@famdouma.nl> | 2020-01-30 13:24:10 +0100 |
---|---|---|
committer | Roeland Jago Douma <roeland@famdouma.nl> | 2020-01-30 14:03:28 +0100 |
commit | dc1979903ef4c88ad0ae06b40386e2fa339837c2 (patch) | |
tree | 56d647a12c5362df77c21a5c92e1380e406602f9 /apps | |
parent | 9ed106f69acaf419414dccfcfd7efa6de22aa45a (diff) | |
download | nextcloud-server-dc1979903ef4c88ad0ae06b40386e2fa339837c2.tar.gz nextcloud-server-dc1979903ef4c88ad0ae06b40386e2fa339837c2.zip |
Move password settings
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Diffstat (limited to 'apps')
-rw-r--r-- | apps/settings/composer/composer/autoload_classmap.php | 2 | ||||
-rw-r--r-- | apps/settings/composer/composer/autoload_static.php | 2 | ||||
-rw-r--r-- | apps/settings/lib/Settings/Personal/Security/Password.php (renamed from apps/settings/lib/Settings/Personal/Security.php) | 7 | ||||
-rw-r--r-- | apps/settings/templates/settings/personal/security/password.php (renamed from apps/settings/templates/settings/personal/security.php) | 0 | ||||
-rw-r--r-- | apps/settings/tests/Settings/Personal/Security/AuthtokensTest.php | 2 | ||||
-rw-r--r-- | apps/settings/tests/Settings/Personal/Security/PasswordTest.php (renamed from apps/settings/tests/Settings/Personal/SecurityTest.php) | 12 |
6 files changed, 11 insertions, 14 deletions
diff --git a/apps/settings/composer/composer/autoload_classmap.php b/apps/settings/composer/composer/autoload_classmap.php index cf7963ef901..3e83c20bd38 100644 --- a/apps/settings/composer/composer/autoload_classmap.php +++ b/apps/settings/composer/composer/autoload_classmap.php @@ -38,8 +38,8 @@ return array( 'OCA\\Settings\\Middleware\\SubadminMiddleware' => $baseDir . '/../lib/Middleware/SubadminMiddleware.php', 'OCA\\Settings\\Personal\\Additional' => $baseDir . '/../lib/Settings/Personal/Additional.php', 'OCA\\Settings\\Personal\\PersonalInfo' => $baseDir . '/../lib/Settings/Personal/PersonalInfo.php', - 'OCA\\Settings\\Personal\\Security' => $baseDir . '/../lib/Settings/Personal/Security.php', 'OCA\\Settings\\Personal\\Security\\Authtokens' => $baseDir . '/../lib/Settings/Personal/Security/Authtokens.php', + 'OCA\\Settings\\Personal\\Security\\Password' => $baseDir . '/../lib/Settings/Personal/Security/Password.php', 'OCA\\Settings\\Personal\\ServerDevNotice' => $baseDir . '/../lib/Settings/Personal/ServerDevNotice.php', 'OCA\\Settings\\Sections\\Admin\\Additional' => $baseDir . '/../lib/Sections/Admin/Additional.php', 'OCA\\Settings\\Sections\\Admin\\Groupware' => $baseDir . '/../lib/Sections/Admin/Groupware.php', diff --git a/apps/settings/composer/composer/autoload_static.php b/apps/settings/composer/composer/autoload_static.php index f9805dcff11..a76fe97eec9 100644 --- a/apps/settings/composer/composer/autoload_static.php +++ b/apps/settings/composer/composer/autoload_static.php @@ -53,8 +53,8 @@ class ComposerStaticInitSettings 'OCA\\Settings\\Middleware\\SubadminMiddleware' => __DIR__ . '/..' . '/../lib/Middleware/SubadminMiddleware.php', 'OCA\\Settings\\Personal\\Additional' => __DIR__ . '/..' . '/../lib/Settings/Personal/Additional.php', 'OCA\\Settings\\Personal\\PersonalInfo' => __DIR__ . '/..' . '/../lib/Settings/Personal/PersonalInfo.php', - 'OCA\\Settings\\Personal\\Security' => __DIR__ . '/..' . '/../lib/Settings/Personal/Security.php', 'OCA\\Settings\\Personal\\Security\\Authtokens' => __DIR__ . '/..' . '/../lib/Settings/Personal/Security/Authtokens.php', + 'OCA\\Settings\\Personal\\Security\\Password' => __DIR__ . '/..' . '/../lib/Settings/Personal/Security/Password.php', 'OCA\\Settings\\Personal\\ServerDevNotice' => __DIR__ . '/..' . '/../lib/Settings/Personal/ServerDevNotice.php', 'OCA\\Settings\\Sections\\Admin\\Additional' => __DIR__ . '/..' . '/../lib/Sections/Admin/Additional.php', 'OCA\\Settings\\Sections\\Admin\\Groupware' => __DIR__ . '/..' . '/../lib/Sections/Admin/Groupware.php', diff --git a/apps/settings/lib/Settings/Personal/Security.php b/apps/settings/lib/Settings/Personal/Security/Password.php index f571be0c220..91d8b9228e8 100644 --- a/apps/settings/lib/Settings/Personal/Security.php +++ b/apps/settings/lib/Settings/Personal/Security/Password.php @@ -1,4 +1,5 @@ <?php +declare(strict_types=1); /** * @copyright Copyright (c) 2017 Arthur Schiwon <blizzz@arthur-schiwon.de> * @@ -25,13 +26,13 @@ * */ -namespace OCA\Settings\Personal; +namespace OCA\Settings\Personal\Security; use OCP\AppFramework\Http\TemplateResponse; use OCP\IUserManager; use OCP\Settings\ISettings; -class Security implements ISettings { +class Password implements ISettings { /** @var IUserManager */ private $userManager; @@ -52,7 +53,7 @@ class Security implements ISettings { $passwordChangeSupported = $user->canChangePassword(); } - return new TemplateResponse('settings', 'settings/personal/security', [ + return new TemplateResponse('settings', 'settings/personal/security/password', [ 'passwordChangeSupported' => $passwordChangeSupported, ]); } diff --git a/apps/settings/templates/settings/personal/security.php b/apps/settings/templates/settings/personal/security/password.php index 23959f7d9c2..23959f7d9c2 100644 --- a/apps/settings/templates/settings/personal/security.php +++ b/apps/settings/templates/settings/personal/security/password.php diff --git a/apps/settings/tests/Settings/Personal/Security/AuthtokensTest.php b/apps/settings/tests/Settings/Personal/Security/AuthtokensTest.php index 6837fc101c4..6fd7cf22efe 100644 --- a/apps/settings/tests/Settings/Personal/Security/AuthtokensTest.php +++ b/apps/settings/tests/Settings/Personal/Security/AuthtokensTest.php @@ -29,7 +29,7 @@ namespace OCA\Settings\Tests\Settings\Personal\Security; use OC\Authentication\Token\DefaultToken; use OC\Authentication\Token\IProvider as IAuthTokenProvider; -use OCA\Settings\Personal\Security; +use OCA\Settings\Personal\Password; use OCA\Settings\Personal\Security\Authtokens; use OCP\AppFramework\Http\TemplateResponse; use OCP\IInitialStateService; diff --git a/apps/settings/tests/Settings/Personal/SecurityTest.php b/apps/settings/tests/Settings/Personal/Security/PasswordTest.php index 103bd9dae92..160e4ebf844 100644 --- a/apps/settings/tests/Settings/Personal/SecurityTest.php +++ b/apps/settings/tests/Settings/Personal/Security/PasswordTest.php @@ -1,5 +1,4 @@ <?php - declare(strict_types=1); /** @@ -28,17 +27,14 @@ declare(strict_types=1); namespace OCA\Settings\Tests\Settings\Personal; -use OC\Authentication\TwoFactorAuth\ProviderLoader; -use OCA\Settings\Personal\Security; +use OCA\Settings\Personal\Security\Password; use OCP\AppFramework\Http\TemplateResponse; -use OCP\IConfig; use OCP\IUser; use OCP\IUserManager; -use OCP\IUserSession; use PHPUnit\Framework\MockObject\MockObject; use Test\TestCase; -class SecurityTest extends TestCase { +class PasswordTest extends TestCase { /** @var IUserManager|MockObject */ private $userManager; @@ -46,7 +42,7 @@ class SecurityTest extends TestCase { /** @var string */ private $uid; - /** @var Security */ + /** @var Password */ private $section; protected function setUp(): void { @@ -55,7 +51,7 @@ class SecurityTest extends TestCase { $this->userManager = $this->createMock(IUserManager::class); $this->uid = 'test123'; - $this->section = new Security( + $this->section = new Password( $this->userManager, $this->uid ); |