Skip to content

Commit eec397c

Browse files
committed
tidy
1 parent 6cd0988 commit eec397c

File tree

1 file changed

+13
-10
lines changed

1 file changed

+13
-10
lines changed

lib/MetaCPAN/Server/Controller/Changes.pm

+13-10
Original file line numberDiff line numberDiff line change
@@ -70,33 +70,36 @@ sub by_releases : Path('by_releases') : Args(0) {
7070

7171
# ArrayRef[ Dict[ author => Str, name => Str ] ]
7272
my $arg = $c->read_param("releases");
73-
my $ret = $c->model('CPAN::Release')->by_author_and_names( $arg );
73+
my $ret = $c->model('CPAN::Release')->by_author_and_names($arg);
7474

7575
my @changes;
76-
for my $release (@{$ret->{releases}}) {
77-
my ($author, $name, $path) = @{$release}{ qw(author name changes_file) };
76+
for my $release ( @{ $ret->{releases} } ) {
77+
my ( $author, $name, $path )
78+
= @{$release}{qw(author name changes_file)};
7879
my $source = $c->model('Source')->path( $author, $name, $path ) // '';
7980

8081
my $content;
8182
try {
8283
local $/;
8384
$content = Encode::decode(
8485
'UTF-8',
85-
(scalar $source->openr->getline),
86+
( scalar $source->openr->getline ),
8687
Encode::FB_CROAK | Encode::LEAVE_SRC
8788
);
88-
} catch {
89+
}
90+
catch {
8991
$content = undef;
9092
};
9193

92-
push @changes, {
93-
author => $author,
94-
release => $name,
94+
push @changes,
95+
{
96+
author => $author,
97+
release => $name,
9598
changes_text => $content,
96-
}
99+
};
97100
}
98101

99-
$c->stash({ changes => \@changes });
102+
$c->stash( { changes => \@changes } );
100103
}
101104

102105
1;

0 commit comments

Comments
 (0)