Skip to content

Commit

Permalink
Revert "use keys/each for array"
Browse files Browse the repository at this point in the history
it seems using "each" with "redo" is not an good idea

This reverts commit f0d6e5b.
  • Loading branch information
kaz-utashiro committed Nov 21, 2023
1 parent f0d6e5b commit 1826d5c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/Text/Conceal.pm
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,8 @@ sub decode {
my @replace = @{$obj->{replace}} or return @_;
ARGS:
for (@_) {
while (my($i, $r) = each @replace) {
my($regex, $orig, $len) = @$r;
for my $i (0 .. $#replace) {
my($regex, $orig, $len) = @{$replace[$i]};
if (s/$regex/_replace(${^MATCH}, $orig, $len)/pe) {
if ($obj->{duplicate}) {
;
Expand Down

0 comments on commit 1826d5c

Please sign in to comment.