Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F584995
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
View Options
diff --git a/includes/media/MediaTransformOutput.php b/includes/media/MediaTransformOutput.php
index 89fdc72177d..73e525a3b00 100644
--- a/includes/media/MediaTransformOutput.php
+++ b/includes/media/MediaTransformOutput.php
@@ -198,16 +198,18 @@ abstract class MediaTransformOutput {
}
if ( $this->path === null ) {
- return $this->file->getLocalRefPath(); // assume thumb was not scaled
+ // assume thumb was not scaled
+ return $this->file->getLocalRefPath();
}
if ( FileBackend::isStoragePath( $this->path ) ) {
$be = $this->file->getRepo()->getBackend();
- // The temp file will be process cached by FileBackend
+ // The temp file is process-cached by FileBackend
$fsFile = $be->getLocalReference( [ 'src' => $this->path ] );
return $fsFile ? $fsFile->getPath() : false;
}
- return $this->path; // may return false
+ // may return false
+ return $this->path;
}
/**
@@ -230,16 +232,17 @@ abstract class MediaTransformOutput {
[ 'src' => $this->path, 'headers' => $headers, ]
)
);
- } else {
- $streamer = new HTTPFileStreamer(
- $this->getLocalCopyPath(),
- $repo ? $repo->getBackend()->getStreamerOptions() : []
- );
-
- $success = $streamer->stream( $headers );
- return $success ? Status::newGood()
- : Status::newFatal( 'backend-fail-stream', $this->path );
}
+
+ $streamer = new HTTPFileStreamer(
+ $this->getLocalCopyPath(),
+ $repo ? $repo->getBackend()->getStreamerOptions() : []
+ );
+
+ $success = $streamer->stream( $headers );
+
+ return $success ? Status::newGood()
+ : Status::newFatal( 'backend-fail-stream', $this->path );
}
/**
File Metadata
Details
Attached
Mime Type
text/x-diff
Expires
Sat, Jul 5, 5:31 AM (11 h, 28 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
227457
Default Alt Text
(1 KB)
Attached To
Mode
rMW mediawiki
Attached
Detach File
Event Timeline
Log In to Comment