remove: Avoid $_ breakage. (Stupid, stupid perl.)

This avoids another one of those $_ scoping issues where a deep call to a
function that changes $_ clobbers the array that is being looped over.
master
Joey Hess 2008-10-06 16:10:47 -04:00
parent f504df45bc
commit fea76a11bc
2 changed files with 9 additions and 1 deletions

View File

@ -98,7 +98,9 @@ sub removal_confirm ($$@) { #{{{
my $attachment=shift;
my @pages=@_;
check_canremove($_, $q, $session) foreach @pages;
foreach my $page (@pages) {
check_canremove($page, $q, $session);
}
# Save current form state to allow returning to it later
# without losing any edits.

6
debian/changelog vendored
View File

@ -1,3 +1,9 @@
ikiwiki (2.67) UNRELEASED; urgency=low
* remove: Avoid $_ breakage. (Stupid, stupid perl.)
-- Joey Hess <joeyh@debian.org> Mon, 06 Oct 2008 16:07:50 -0400
ikiwiki (2.66) unstable; urgency=low
* recentchanges: Fix redirects to non-page files.