From cc03986ca19863639a1e18565b19e9a233abb64e Mon Sep 17 00:00:00 2001 From: Alexandre Emsenhuber Date: Tue, 12 Aug 2014 20:15:53 +0200 Subject: [PATCH] resourceloader: Fix undefined variable in ResourceLoaderFileModule::getSkipFunction Follows-up 75c08916b02ac87. Looking at the call chain of validateScriptFile() up to JSTokenzier, the first parameter is the file name, otherwise "[inline]" is used; so that variable should be $localPath. Bug: 69214 Change-Id: If7f36449cb352f50ba795a6d306e5d949a3dbd29 --- includes/resourceloader/ResourceLoaderFileModule.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/resourceloader/ResourceLoaderFileModule.php b/includes/resourceloader/ResourceLoaderFileModule.php index f646ae9f15..06f7146d78 100644 --- a/includes/resourceloader/ResourceLoaderFileModule.php +++ b/includes/resourceloader/ResourceLoaderFileModule.php @@ -479,7 +479,7 @@ class ResourceLoaderFileModule extends ResourceLoaderModule { } $contents = file_get_contents( $localPath ); if ( $this->getConfig()->get( 'ResourceLoaderValidateStaticJS' ) ) { - $contents = $this->validateScriptFile( $fileName, $contents ); + $contents = $this->validateScriptFile( $localPath, $contents ); } return $contents; } -- 2.20.1