- 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
# Validate the signature and clean it up as needed
if( $this->mToggles['fancysig'] ) {
# 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' ) );
$this->mNick = Parser::cleanSig( $this->mNick );
} else {
$this->mainPrefsForm( 'error', wfMsg( 'badsig' ) );