From: Ævar Arnfjörð Bjarmason Date: Sun, 8 Jan 2006 03:12:54 +0000 (+0000) Subject: * Fixed bugs introduced in revision 1.155 by rob ;) X-Git-Tag: 1.6.0~704 X-Git-Url: http://git.cyclocoop.org/%7B%24admin_url%7Dcompta/comptes/journal.php?a=commitdiff_plain;h=4e2e709e0cb1c307201f3b439a92bda75b387113;p=lhc%2Fweb%2Fwiklou.git * Fixed bugs introduced in revision 1.155 by rob ;) - Using $x === false, if ($x) is a logic error in this case because PHP thinks (among other things) that (int)0 and (string)0 are false, so a custom signiture that was "0" would fail --- diff --git a/includes/SpecialPreferences.php b/includes/SpecialPreferences.php index 3f803175a4..7a2e76d0b1 100644 --- a/includes/SpecialPreferences.php +++ b/includes/SpecialPreferences.php @@ -229,7 +229,7 @@ class PreferencesForm { # Validate the signature and clean it up as needed if( $this->mToggles['fancysig'] ) { - if( Parser::validateSig( $this->mNick ) ) { + if( Parser::validateSig( $this->mNick ) !== false ) { $this->mNick = Parser::cleanSig( $this->mNick ); } else { $this->mainPrefsForm( 'error', wfMsg( 'badsig' ) );