Aaron Schulz has uploaded a new change for review.
https://gerrit.wikimedia.org/r/63222
Change subject: [FileBackend] Optimize the case were no operations are provided.
......................................................................
[FileBackend] Optimize the case were no operations are provided.
Change-Id: Iaf858ce2e8b21e031d27b984029f0424518201af
(cherry picked from commit 6b1194b9dadeff80b51d6af7c56c97244a92a058)
---
M includes/filebackend/FileBackendStore.php
1 file changed, 8 insertions(+), 0 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core
refs/changes/22/63222/1
diff --git a/includes/filebackend/FileBackendStore.php
b/includes/filebackend/FileBackendStore.php
index 5fb1840..702714b2 100644
--- a/includes/filebackend/FileBackendStore.php
+++ b/includes/filebackend/FileBackendStore.php
@@ -1132,6 +1132,10 @@
wfProfileIn( __METHOD__ . '-' . $this->name );
$status = Status::newGood();
+ if ( !count( $ops ) ) {
+ return $status; // nothing to do
+ }
+
// Fix up custom header name/value pairs...
$ops = array_map( array( $this, 'stripInvalidHeadersFromOp' ),
$ops );
@@ -1184,6 +1188,10 @@
wfProfileIn( __METHOD__ . '-' . $this->name );
$status = Status::newGood();
+ if ( !count( $ops ) ) {
+ return $status; // nothing to do
+ }
+
// Fix up custom header name/value pairs...
$ops = array_map( array( $this, 'stripInvalidHeadersFromOp' ),
$ops );
--
To view, visit https://gerrit.wikimedia.org/r/63222
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iaf858ce2e8b21e031d27b984029f0424518201af
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/core
Gerrit-Branch: wmf/1.22wmf3
Gerrit-Owner: Aaron Schulz <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits