From: Kunal Mehta Date: Mon, 16 Mar 2015 16:47:48 +0000 (-0700) Subject: registration: Fix merging of $wgExtensionCredits X-Git-Tag: 1.31.0-rc.0~12081^2 X-Git-Url: http://git.cyclocoop.org/%28%5B%5E/404?a=commitdiff_plain;h=da17b9bf74e6b074e3c38b358485bc31431533a3;p=lhc%2Fweb%2Fwiklou.git registration: Fix merging of $wgExtensionCredits $wgExtensionCredits has two-levels of arrays, so it needs to be merged recursively. Bug: T91609 Change-Id: I4e5fc50059745a89fb69bc1e05a299fd9aaee968 --- diff --git a/includes/registration/ExtensionRegistry.php b/includes/registration/ExtensionRegistry.php index 5b18e72ddb..52e860c32a 100644 --- a/includes/registration/ExtensionRegistry.php +++ b/includes/registration/ExtensionRegistry.php @@ -142,8 +142,8 @@ class ExtensionRegistry { foreach ( $info['globals'] as $key => $val ) { if ( !isset( $GLOBALS[$key] ) || !$GLOBALS[$key] ) { $GLOBALS[$key] = $val; - } elseif ( $key === 'wgHooks' ) { - // Special case $wgHooks, which requires a recursive merge. + } elseif ( $key === 'wgHooks' || $key === 'wgExtensionCredits' ) { + // Special case $wgHooks and $wgExtensionCredits, which require a recursive merge. // Ideally it would have been taken care of in the first if block though. $GLOBALS[$key] = array_merge_recursive( $GLOBALS[$key], $val ); } elseif ( $key === 'wgGroupPermissions' ) {