Merge "GlobalVarConfig shouldn't throw exceptions for null-valued config settings"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Mon, 23 Jun 2014 19:08:21 +0000 (19:08 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Mon, 23 Jun 2014 19:08:21 +0000 (19:08 +0000)
includes/config/GlobalVarConfig.php

index 61a76b7..0d7f3f0 100644 (file)
@@ -69,7 +69,7 @@ class GlobalVarConfig implements Config {
         */
        protected function getWithPrefix( $prefix, $name ) {
                $var = $prefix . $name;
-               if ( !isset( $GLOBALS[ $var ] ) ) {
+               if ( !array_key_exists( $var, $GLOBALS ) ) {
                        throw new ConfigException( __METHOD__ . ": undefined variable: '$var'" );
                }
                return $GLOBALS[ $var ];