Set a title for the context during import on the cli
authorMark A. Hershberger <mah@everybody.org>
Mon, 10 Mar 2014 02:17:01 +0000 (22:17 -0400)
committerMark A. Hershberger <mah@everybody.org>
Mon, 10 Mar 2014 02:17:01 +0000 (22:17 -0400)
Bug: 62467
Change-Id: I9e0b6a219ea4176f9a3d14b8dbbea08b36c76c59

maintenance/importTextFile.php

index dadc84a..c7df6c3 100644 (file)
@@ -42,6 +42,7 @@ if ( count( $args ) < 1 || isset( $options['help'] ) ) {
 
                        echo "\nUsing title '" . $title->getPrefixedText() . "'...";
                        if ( !$title->exists() || !isset( $options['nooverwrite'] ) ) {
+                               RequestContext::getMain()->setTitle( $title );
 
                                $text = file_get_contents( $filename );
                                $user = isset( $options['user'] ) ? $options['user'] : 'Maintenance script';