deferred: Fix MW version number when hard deprecating to '1.34'
authorDerick Alangi <alangiderick@gmail.com>
Wed, 11 Sep 2019 17:41:05 +0000 (18:41 +0100)
committerDerick Alangi <alangiderick@gmail.com>
Wed, 11 Sep 2019 18:15:43 +0000 (19:15 +0100)
Should be string or bool and not a float. The reason 49bbfc7 was
not triggered is because the deprecated code path is no longer being
executed in production.

Change-Id: Ieeffb8a6cc7177c52b4c54d66152c90ded1dc248

includes/deferred/SearchUpdate.php

index a508746..84f6fc0 100644 (file)
@@ -50,7 +50,7 @@ class SearchUpdate implements DeferrableUpdate {
         */
        public function __construct( $id, $title, $c = null ) {
                if ( is_string( $title ) ) {
-                       wfDeprecated( __METHOD__ . " with a string for the title", 1.34 );
+                       wfDeprecated( __METHOD__ . " with a string for the title", '1.34' );
                        $this->title = Title::newFromText( $title );
                        if ( $this->title === null ) {
                                throw new InvalidArgumentException( "Cannot construct the title: $title" );
@@ -62,10 +62,10 @@ class SearchUpdate implements DeferrableUpdate {
                $this->id = $id;
                // is_string() check is back-compat for ApprovedRevs
                if ( is_string( $c ) ) {
-                       wfDeprecated( __METHOD__ . " with a string for the content", 1.34 );
+                       wfDeprecated( __METHOD__ . " with a string for the content", '1.34' );
                        $c = new TextContent( $c );
                } elseif ( is_bool( $c ) ) {
-                       wfDeprecated( __METHOD__ . " with a boolean for the content", 1.34 );
+                       wfDeprecated( __METHOD__ . " with a boolean for the content", '1.34' );
                        $c = null;
                }
                $this->content = $c;