Skip to content

Commit f01c570

Browse files
author
Saket Hatwar
committed
lint
1 parent c0e0aa5 commit f01c570

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

modules/my_preferences/php/my_preferences.class.inc

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
1-
<?php
2-
3-
declare(strict_types=1);
1+
<?php declare(strict_types=1);
42

53
namespace LORIS\my_preferences;
64

@@ -13,11 +11,10 @@ class My_Preferences extends \NDB_Form
1311
{
1412
// Use gettext for error messages
1513
private const PASSWORD_ERROR_IS_EMAIL = 'Your password cannot be your email.';
16-
private const PASSWORD_ERROR_IS_USER
17-
= 'Your password cannot be your user name.';
14+
private const PASSWORD_ERROR_IS_USER = 'Your password cannot be your user name.';
1815
private const PASSWORD_ERROR_NO_MATCH = 'The passwords do not match.';
1916
private const PASSWORD_ERROR_NO_CHANGE
20-
= 'New and old passwords are identical: please choose another one';
17+
= 'New and old passwords are identical: please choose another one';
2118

2219
/**
2320
* Computes the initial values this page will be filled with.
@@ -464,11 +461,7 @@ class My_Preferences extends \NDB_Form
464461
$decoded = htmlspecialchars_decode($plaintext);
465462
new \Password($decoded);
466463
// New password must be different than current one
467-
if (
468-
! \User::factory($this->identifier)->isPasswordDifferent(
469-
$decoded
470-
)
471-
) {
464+
if (! \User::factory($this->identifier)->isPasswordDifferent($decoded)) {
472465
$errors['Password_Group'] = dgettext(
473466
'my_preferences',
474467
self::PASSWORD_ERROR_NO_CHANGE

0 commit comments

Comments
 (0)