Merge "StreamFile: Deprecate ::parseRange() and ::send404Message() methods"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Sat, 14 Sep 2019 01:03:47 +0000 (01:03 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Sat, 14 Sep 2019 01:03:47 +0000 (01:03 +0000)
RELEASE-NOTES-1.34
includes/StreamFile.php

index d2dbce1..2da3b55 100644 (file)
@@ -565,6 +565,9 @@ because of Phabricator reports.
 * The GetBlockedStatus hook is deprecated. Use GetUserBlock instead, to add or
   remove a block.
 * $wgContentHandlerUseDB is deprecated and should always be true.
+* StreamFile::send404Message() and StreamFile::parseRange() are now deprecated.
+  Use HTTPFileStreamer::send404Message() and HTTPFileStreamer::parseRange()
+  respectively instead.
 
 === Other changes in 1.34 ===
 * …
index 2afd651..c9b2c33 100644 (file)
@@ -68,8 +68,10 @@ class StreamFile {
         * @param string $fname Full name and path of the file to stream
         * @param int $flags Bitfield of STREAM_* constants
         * @since 1.24
+        * @deprecated since 1.34, use HTTPFileStreamer::send404Message() instead
         */
        public static function send404Message( $fname, $flags = 0 ) {
+               wfDeprecated( __METHOD__, '1.34' );
                HTTPFileStreamer::send404Message( $fname, $flags );
        }
 
@@ -80,8 +82,10 @@ class StreamFile {
         * @param int $size File size
         * @return array|string Returns error string on failure (start, end, length)
         * @since 1.24
+        * @deprecated since 1.34, use HTTPFileStreamer::parseRange() instead
         */
        public static function parseRange( $range, $size ) {
+               wfDeprecated( __METHOD__, '1.34' );
                return HTTPFileStreamer::parseRange( $range, $size );
        }