From: Mark A. Hershberger Date: Sat, 21 Jun 2014 18:37:42 +0000 (-0400) Subject: Don't allow some E_NOTICE messages to end up in the LocalSettings.php X-Git-Tag: 1.31.0-rc.0~15279^2 X-Git-Url: https://git.cyclocoop.org/?a=commitdiff_plain;h=d6f51c5aa53d665f62ebc28870c53698896402f7;p=lhc%2Fweb%2Fwiklou.git Don't allow some E_NOTICE messages to end up in the LocalSettings.php There is probably a better, more comprehensive way to produce a LocalSettings.php file so that E_STRICT and E_NOTICE errors don't end up in the file, or to notify users that there is a problem with the generated file, at least. This only attempts to address those issues reported as a result of c978cee8562f018dab158b41e15266fcf873bf1b. Bug: 66922 Change-Id: I0fe70446d9fe23aed2a147e20e5ff3851371726d --- diff --git a/includes/installer/LocalSettingsGenerator.php b/includes/installer/LocalSettingsGenerator.php index 5e89ca4aa9..3c8a5b1d40 100644 --- a/includes/installer/LocalSettingsGenerator.php +++ b/includes/installer/LocalSettingsGenerator.php @@ -221,9 +221,12 @@ class LocalSettingsGenerator { wfBoolToStr( $perm ) . ";\n"; } } - if ( $this->groupPermissions['*']['edit'] === false - && $this->groupPermissions['*']['createaccount'] === false - && $this->groupPermissions['*']['read'] !== false + if ( ( isset( $this->groupPermissions['*']['edit'] ) && + $this->groupPermissions['*']['edit'] === false ) + && ( isset( $this->groupPermissions['*']['createaccount'] ) && + $this->groupPermissions['*']['createaccount'] === false ) + && ( isset( $this->groupPermissions['*']['read'] ) && + $this->groupPermissions['*']['read'] !== false ) ) { $noFollow = "\n# Set \$wgNoFollowLinks to true if you open up your wiki to editing by\n" . "# the general public and wish to apply nofollow to external links as a\n"