fix: Shouldn't modify $_ in list, PBP p114
This commit is contained in:
parent
e5758898a5
commit
a30587f7ad
1 changed files with 4 additions and 2 deletions
|
|
@ -857,8 +857,10 @@ sub processPropertiesFromFormPost {
|
|||
# Workaround WebGUI::Session::Form->param bug that returns duplicate
|
||||
# names.
|
||||
my %feeds;
|
||||
$feeds{$_}++
|
||||
for map { s/^feeds-//; $_; } grep /^feeds-/,($form->param());
|
||||
for my $feedId ( grep /^feeds-/, ($form->param()) ) {
|
||||
$feedId =~ s/^feeds-//;
|
||||
$feeds{$feedId}++;
|
||||
}
|
||||
my @feedsFromForm = keys %feeds;
|
||||
|
||||
# Delete old feeds that are not in @feeds
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue