From 84fbe50b535eaa961d7dc92149095b7e8f19acbb Mon Sep 17 00:00:00 2001 From: Aaron Schulz Date: Fri, 19 Apr 2019 20:13:49 -0700 Subject: [PATCH] filerepo: fix return type of FileRepo::streamFileWithStatus() Change-Id: Ibb4610630203e22d921189699f6c51298212d5d3 --- includes/media/MediaTransformOutput.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/includes/media/MediaTransformOutput.php b/includes/media/MediaTransformOutput.php index 9c06ef421c..463a7948d9 100644 --- a/includes/media/MediaTransformOutput.php +++ b/includes/media/MediaTransformOutput.php @@ -202,7 +202,8 @@ abstract class MediaTransformOutput { return Status::newFatal( 'backend-fail-stream', '' ); } elseif ( FileBackend::isStoragePath( $this->path ) ) { $be = $this->file->getRepo()->getBackend(); - return $be->streamFile( [ 'src' => $this->path, 'headers' => $headers ] ); + return Status::wrap( + $be->streamFile( [ 'src' => $this->path, 'headers' => $headers ] ) ); } else { // FS-file $success = StreamFile::stream( $this->getLocalCopyPath(), $headers ); return $success ? Status::newGood() : Status::newFatal( 'backend-fail-stream', $this->path ); -- 2.20.1