http://www.mediawiki.org/wiki/Special:Code/MediaWiki/60964
Revision: 60964 Author: reedy Date: 2010-01-12 07:24:25 +0000 (Tue, 12 Jan 2010) Log Message: ----------- Reversion/followup to r59300 as per Tims comment Modified Paths: -------------- trunk/phase3/includes/MagicWord.php Modified: trunk/phase3/includes/MagicWord.php =================================================================== --- trunk/phase3/includes/MagicWord.php 2010-01-12 07:17:01 UTC (rev 60963) +++ trunk/phase3/includes/MagicWord.php 2010-01-12 07:24:25 UTC (rev 60964) @@ -320,19 +320,19 @@ } /** - * Returns the number of times the text contains the word - * @return int + * Returns true if the text contains the word + * @return bool */ function match( $text ) { - return preg_match( $this->getRegex(), $text ); + return (bool)preg_match( $this->getRegex(), $text ); } /** - * Returns if the text starts with the word - * @return int + * Returns true if the text starts with the word + * @return bool */ function matchStart( $text ) { - return preg_match( $this->getRegexStart(), $text ); + return (bool)preg_match( $this->getRegexStart(), $text ); } /** _______________________________________________ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs