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:
d22bd3c
)
(bug 15952) Don't try to lazy populate sha1 in read-only mode
author
Aaron Schulz
<aaron@users.mediawiki.org>
Sun, 12 Oct 2008 17:07:09 +0000
(17:07 +0000)
committer
Aaron Schulz
<aaron@users.mediawiki.org>
Sun, 12 Oct 2008 17:07:09 +0000
(17:07 +0000)
includes/filerepo/LocalFile.php
patch
|
blob
|
history
diff --git
a/includes/filerepo/LocalFile.php
b/includes/filerepo/LocalFile.php
index
3b20d70
..
c15afc4
100644
(file)
--- a/
includes/filerepo/LocalFile.php
+++ b/
includes/filerepo/LocalFile.php
@@
-1138,7
+1138,7
@@
class LocalFile extends File
// Initialise now if necessary
if ( $this->sha1 == '' && $this->fileExists ) {
$this->sha1 = File::sha1Base36( $this->getPath() );
- if ( strval( $this->sha1 ) != '' ) {
+ if (
!wfReadOnly() &&
strval( $this->sha1 ) != '' ) {
$dbw = $this->repo->getMasterDB();
$dbw->update( 'image',
array( 'img_sha1' => $this->sha1 ),