remember autofiles always
This fixes the problem that it did not remember if an autofile is deleted, unless a plugin happened to register the autofile at the same time. With the new code, we just never recreate an autofile more than once. Only downside is that the list of autofiles is never pruned either. And I don't really see a way to prune it.master
parent
2a0e3787a0
commit
a71b92ed5c
|
@ -692,7 +692,7 @@ sub gen_autofile ($$$) {
|
|||
}
|
||||
|
||||
if ((!defined $file) ||
|
||||
(exists $wikistate{$autofiles{$autofile}{plugin}}{deleted_autofile}{$autofile})) {
|
||||
(exists $wikistate{$autofiles{$autofile}{plugin}}{autofile}{$autofile})) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -702,11 +702,11 @@ sub gen_autofile ($$$) {
|
|||
}
|
||||
|
||||
if (grep { $_ eq $autofile } @$del) {
|
||||
$wikistate{$autofiles{$autofile}{plugin}}{deleted_autofile}{$autofile}=1;
|
||||
return;
|
||||
}
|
||||
|
||||
$autofiles{$autofile}{generator}->();
|
||||
$wikistate{$autofiles{$autofile}{plugin}}{autofile}{$autofile}=1;
|
||||
$pages->{$page}=1;
|
||||
return 1;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue