dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "resources: Register html5shiv as foreign resource"
[lhc/web/wiklou.git]
/
maintenance
/
changePassword.php
diff --git
a/maintenance/changePassword.php
b/maintenance/changePassword.php
index
9fa6632
..
316004b
100644
(file)
--- a/
maintenance/changePassword.php
+++ b/
maintenance/changePassword.php
@@
-46,10
+46,10
@@
class ChangePassword extends Maintenance {
} elseif ( $this->hasOption( "userid" ) ) {
$user = User::newFromId( $this->getOption( 'userid' ) );
} else {
} elseif ( $this->hasOption( "userid" ) ) {
$user = User::newFromId( $this->getOption( 'userid' ) );
} else {
- $this->
error( "A \"user\" or \"userid\" must be set to change the password for", true
);
+ $this->
fatalError( "A \"user\" or \"userid\" must be set to change the password for"
);
}
if ( !$user || !$user->getId() ) {
}
if ( !$user || !$user->getId() ) {
- $this->
error( "No such user: " . $this->getOption( 'user' ), true
);
+ $this->
fatalError( "No such user: " . $this->getOption( 'user' )
);
}
$password = $this->getOption( 'password' );
try {
}
$password = $this->getOption( 'password' );
try {
@@
-64,10
+64,10
@@
class ChangePassword extends Maintenance {
$user->saveSettings();
$this->output( "Password set for " . $user->getName() . "\n" );
} catch ( PasswordError $pwe ) {
$user->saveSettings();
$this->output( "Password set for " . $user->getName() . "\n" );
} catch ( PasswordError $pwe ) {
- $this->
error( $pwe->getText(), true
);
+ $this->
fatalError( $pwe->getText()
);
}
}
}
}
}
}
-$maintClass =
"ChangePassword"
;
+$maintClass =
ChangePassword::class
;
require_once RUN_MAINTENANCE_IF_MAIN;
require_once RUN_MAINTENANCE_IF_MAIN;