dépôts
/
lhc
/
web
/
wiklou.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c0c8bc5
)
Tweak for r29561: don't grab a database object until we need it
author
Brion Vibber
<brion@users.mediawiki.org>
Fri, 11 Jan 2008 04:41:11 +0000
(
04:41
+0000)
committer
Brion Vibber
<brion@users.mediawiki.org>
Fri, 11 Jan 2008 04:41:11 +0000
(
04:41
+0000)
includes/Title.php
patch
|
blob
|
history
diff --git
a/includes/Title.php
b/includes/Title.php
index
2976078
..
e0d5514
100644
(file)
--- a/
includes/Title.php
+++ b/
includes/Title.php
@@
-1256,13
+1256,12
@@
class Title {
* protection, or false if there's none.
*/
public function getTitleProtection() {
- $dbr = wfGetDB( DB_SLAVE );
-
// Can't protect pages in special namespaces
if ( $this->getNamespace() < NS_MAIN ) {
return false;
}
+ $dbr = wfGetDB( DB_SLAVE );
$res = $dbr->select( 'protected_titles', '*',
array ('pt_namespace' => $this->getNamespace(), 'pt_title' => $this->getDBKey()) );