* with this program; if not, write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* http://www.gnu.org/copyleft/gpl.html
- *
*/
/**
* A search suggestion
- *
*/
class SearchSuggestion {
/**
*/
public function setText( $text, $setTitle = true ) {
$this->text = $text;
- if ( $setTitle && $text ) {
+ if ( $setTitle && $text !== '' && $text !== null ) {
$this->setSuggestedTitle( Title::makeTitle( 0, $text ) );
}
}