Content deleted Content added
Updating published sources: DeletionSortingCleaner: * Compensate for someone screwing up {{tl|afd top}} recently. TemplateReplacer16: * Prepare for upcoming run. |
Updating published sources: DeletionSortingCleaner: * List the discussions being archived in the edit summary. |
||
Line 120:
my $intxt=$tok->{'revisions'}[0]{'*'};
my @archive=@{$api->store->{"archive $page"} // []}; # Load saved archivals
my @summary=();
my $fail=undef;
my $outtxt=$api->process_templates($intxt, sub {
Line 211 ⟶ 212:
$date=$1 if $xfdintxt=~m!(\d\d:\d\d, \d+ \w+ \d{4} \(UTC\))!;
unshift @archive, "* [[$name|$name2]] - (".length($xfdintxt).") - $result - <small>closed $date</small>";
push @summary, "[[$name]]";
return '';
});
Line 249 ⟶ 251:
if($outtxt ne $intxt){
$api->log("Archiving closed XfDs from $page...");
$summary="[[$page/archive|Archiving closed XfDs]]".$screwup.": [".scalar(@summary)." discussions]" if length($summary)>250;
$res=$api->edit($tok, $outtxt, $summary, 0, 1);
if($res->{'code'} ne 'success'){
$api->warn("Save failed for $page: ".$res->{'error'}."\n");
|