From 38a6d3e9a4ea8758312946be77d5e419d893f19b Mon Sep 17 00:00:00 2001 From: Glaisher Date: Mon, 13 Jun 2016 17:15:01 +0500 Subject: [PATCH] Use strpos() instead of preg_match() when checking for "/" in Skin::subPageSubtitle Per http://php.net/manual/en/function.preg-match.php#refsect1-function.preg-match-notes Change-Id: I0b2a0e89d77422ed50e5178fcdbbb4e31199fdc8 --- includes/skins/Skin.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/skins/Skin.php b/includes/skins/Skin.php index d70a6b91da..fce68bba4e 100644 --- a/includes/skins/Skin.php +++ b/includes/skins/Skin.php @@ -661,7 +661,7 @@ abstract class Skin extends ContextSource { if ( $out->isArticle() && MWNamespace::hasSubpages( $out->getTitle()->getNamespace() ) ) { $ptext = $this->getTitle()->getPrefixedText(); - if ( preg_match( '/\//', $ptext ) ) { + if ( strpos( $ptext, '/' ) !== false ) { $links = explode( '/', $ptext ); array_pop( $links ); $c = 0; -- 2.20.1