Skip to content

Commit 97099d0

Browse files
author
River Tarnell
committed
don't allow empty searches
1 parent dce1b0a commit 97099d0

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

includes/SearchEngine.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -298,6 +298,9 @@ function parseQuery()
298298
{
299299
global $wgDBminWordLen, $wgLang, $wgDBmysql4;
300300

301+
if (strlen($this->mUsertext) < 1)
302+
return MW_SEARCH_BAD_QUERY;
303+
301304
if( $wgDBmysql4 ) {
302305
# Use cleaner boolean search if available
303306
return $this->parseQuery4();

0 commit comments

Comments
 (0)