diff --git a/src/SpecialPage/SpecialResourceLoaderArticles.php b/src/SpecialPage/SpecialResourceLoaderArticles.php index 24c9086..6bebb25 100644 --- a/src/SpecialPage/SpecialResourceLoaderArticles.php +++ b/src/SpecialPage/SpecialResourceLoaderArticles.php @@ -143,7 +143,7 @@ public function addPageCB( $formData ) { $store = false; } elseif ( ( - ( substr( $formData[ 'Page' ], -4 ) !== '.css' || substr( $formData[ 'Page' ], -5 ) !== '.less' ) + !( substr( $formData[ 'Page' ], -4 ) === '.css' || substr( $formData[ 'Page' ], -5 ) === '.less' ) && $formData[ 'Type' ] === 'style' ) || ( substr( $formData[ 'Page' ], -3 ) !== '.js' && $formData[ 'Type' ] === 'script' ) @@ -240,7 +240,7 @@ public function editPageCB( $formData ) { $store = false; } elseif ( ( - ( substr( $formData[ 'Page' ], -4 ) !== '.css' || substr( $formData[ 'Page' ], -5 ) !== '.less' ) + !( substr( $formData[ 'Page' ], -4 ) === '.css' || substr( $formData[ 'Page' ], -5 ) === '.less' ) && $formData[ 'Type' ] === 'style' ) || ( substr( $formData[ 'Page' ], -3 ) !== '.js' && $formData[ 'Type' ] === 'script' )