dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "Make JobQueueRedis stat calls match the DB one"
[lhc/web/wiklou.git]
/
includes
/
PrefixSearch.php
diff --git
a/includes/PrefixSearch.php
b/includes/PrefixSearch.php
index
55a4f49
..
430b4b8
100644
(file)
--- a/
includes/PrefixSearch.php
+++ b/
includes/PrefixSearch.php
@@
-362,7
+362,11
@@
abstract class PrefixSearch {
$ns = NS_MAIN; // if searching on many always default to main
}
$ns = NS_MAIN; // if searching on many always default to main
}
- $t = Title::newFromText( $search, $ns );
+ $t = null;
+ if ( is_string( $search ) ) {
+ $t = Title::newFromText( $search, $ns );
+ }
+
$prefix = $t ? $t->getDBkey() : '';
$dbr = wfGetDB( DB_SLAVE );
$res = $dbr->select( 'page',
$prefix = $t ? $t->getDBkey() : '';
$dbr = wfGetDB( DB_SLAVE );
$res = $dbr->select( 'page',