PasswordFactory: Hard-deprecate init(), deprecated since 1.32
Depends-On: If2a36938d5aacdf3bd4ac44cc6b097ddc2415b70 Depends-On: I7c670dd57296cf4add4ad1af941e1c3cf28a4e71 Change-Id: Iade89df3aa89d6fac5b783e4cbda73be1648c50e
This commit is contained in:
parent
381cb186e2
commit
b773fced63
3 changed files with 4 additions and 0 deletions
|
|
@ -1035,6 +1035,7 @@ because of Phabricator reports.
|
|||
- TablePager::getBody(), deprecated since 1.24
|
||||
- ContentHandler::getSlotDiffRendererInternal(), deprecated since 1.35
|
||||
- ParserOutput::getCategories(), deprecated since 1.40
|
||||
- PasswordFactory::init(), deprecated since 1.32
|
||||
* WikitextContent::getRedirectTargetAndText has been deprecated, use
|
||||
WikitextContentHandler::extractRedirectTargetAndText instead.
|
||||
* WikiPage::doDeleteArticleBatched, deprecated in 1.37, now emits deprecation
|
||||
|
|
|
|||
|
|
@ -109,12 +109,14 @@ final class PasswordFactory {
|
|||
|
||||
/**
|
||||
* @deprecated since 1.32 Initialize settings using the constructor
|
||||
* Emitting deprecation warnings since 1.41.
|
||||
*
|
||||
* Initialize the internal static variables using the global variables
|
||||
*
|
||||
* @param Config $config Configuration object to load data from
|
||||
*/
|
||||
public function init( Config $config ): void {
|
||||
wfDeprecated( __METHOD__, '1.32' );
|
||||
foreach ( $config->get( MainConfigNames::PasswordConfig ) as $type => $options ) {
|
||||
$this->register( $type, $options );
|
||||
}
|
||||
|
|
|
|||
|
|
@ -46,6 +46,7 @@ class PasswordFactoryTest extends MediaWikiUnitTestCase {
|
|||
}
|
||||
|
||||
public function testInit() {
|
||||
$this->expectDeprecationAndContinue( '/deprecated in MediaWiki 1.32/' );
|
||||
$config = new HashConfig( [
|
||||
MainConfigNames::PasswordConfig => [
|
||||
'foo' => [ 'class' => InvalidPassword::class ],
|
||||
|
|
|
|||
Loading…
Reference in a new issue