userManager = $userManager; $this->uid = $UserId; } public function getForm(): TemplateResponse { $user = $this->userManager->get($this->uid); $passwordChangeSupported = false; if ($user !== null) { $passwordChangeSupported = $user->canChangePassword(); } return new TemplateResponse('settings', 'settings/personal/security/password', [ 'passwordChangeSupported' => $passwordChangeSupported, ]); } public function getSection(): string { return 'security'; } public function getPriority(): int { return 10; } }