From 5a5784a58d0c100c960e3a8bad08c9253b25b25a Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bartosz=20Dziewo=C5=84ski?= Date: Thu, 7 May 2015 15:51:09 +0200 Subject: [PATCH] resourceloader: Fix fatal when using $wgResourceModuleSkinStyles with "+" Fatal error: [] operator not supported for strings in includes/resourceloader/ResourceLoader.php on line 354 This would occur when a skin customized ResourceModuleSkinStyles using the '+' syntax, which preserves default skinStyles, and the default skinStyles was defined as a string rather than array. Change-Id: I6cd12a638d562c75bc4704e098de84f3882248b6 --- includes/resourceloader/ResourceLoader.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/resourceloader/ResourceLoader.php b/includes/resourceloader/ResourceLoader.php index 7da3aec8e7..ce18c32add 100644 --- a/includes/resourceloader/ResourceLoader.php +++ b/includes/resourceloader/ResourceLoader.php @@ -339,7 +339,7 @@ class ResourceLoader { } elseif ( isset( $skinStyles['+' . $name] ) ) { $paths = (array)$skinStyles['+' . $name]; $styleFiles = isset( $this->moduleInfos[$name]['skinStyles']['default'] ) ? - $this->moduleInfos[$name]['skinStyles']['default'] : + (array)$this->moduleInfos[$name]['skinStyles']['default'] : array(); } else { continue; -- 2.20.1