From 6c695ae7c8be363a0ed845ff94aece9e8d42f51d Mon Sep 17 00:00:00 2001 From: Manuel Schneider <80686@users.mediawiki.org> Date: Wed, 13 Dec 2006 10:26:37 +0000 Subject: [PATCH] added additional check to avoid warnings --- includes/Title.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/includes/Title.php b/includes/Title.php index 8912dbc6ea..e1ee2ac629 100644 --- a/includes/Title.php +++ b/includes/Title.php @@ -1223,7 +1223,12 @@ class Title { */ function isSubpage() { global $wgNamespacesWithSubpages; - return ( strpos( $this->getText(), '/' ) !== false && $wgNamespacesWithSubpages[ $this->mNamespace ] == true ); + + if( isset( $wgNamespacesWithSubpages[ $this->mNamespace ] ) ) { + return ( strpos( $this->getText(), '/' ) !== false && $wgNamespacesWithSubpages[ $this->mNamespace ] == true ); + } else { + return false; + } } /** -- 2.20.1