Hooks: Initialise array inline

Change-Id: I13548d37faa7169951c58279c962f6c2f4f87b60
This commit is contained in:
Reedy 2024-12-11 15:40:27 +00:00
parent a52c16451a
commit 6dceb40122

View file

@ -234,11 +234,11 @@ class Hooks implements
/** @inheritDoc */
public function onResourceLoaderRegisterModules( ResourceLoader $resourceLoader ): void {
$extensionRegistry = ExtensionRegistry::getInstance();
$messages = [];
$messages[] = 'colon-separator';
$messages[] = 'captcha-edit';
$messages[] = 'captcha-label';
$messages = [
'colon-separator',
'captcha-edit',
'captcha-label'
];
if ( $extensionRegistry->isLoaded( 'QuestyCaptcha' ) ) {
$messages[] = 'questycaptcha-edit';