Fix handling of ar_length and ar_sha1 in RevisionArchiveRecord.
[lhc/web/wiklou.git] / includes / MovePage.php
index fe82465..fc9f6a6 100644 (file)
@@ -597,7 +597,12 @@ class MovePage {
 
                                $redirectArticle->doEditUpdates( $redirectRevision, $user, [ 'created' => true ] );
 
-                               ChangeTags::addTags( $changeTags, null, $redirectRevId, null );
+                               // make a copy because of log entry below
+                               $redirectTags = $changeTags;
+                               if ( in_array( 'mw-new-redirect', ChangeTags::getSoftwareTags() ) ) {
+                                       $redirectTags[] = 'mw-new-redirect';
+                               }
+                               ChangeTags::addTags( $redirectTags, null, $redirectRevId, null );
                        }
                }