Skip to content

Commit af66c89

Browse files
committed
Remove unexpected characters from the action
1 parent 5bafae0 commit af66c89

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lib/pause_2017/PAUSE/Web/Plugin/RenderYAML.pm

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ sub register {
1313
my $dump = YAML::Syck::Dump($data);
1414
my $edump = Encode::encode_utf8($dump);
1515
my $action = $c->req->param('ACTION') || 'pause';
16+
$action =~ tr/a-z0-9_//cd;
1617
$c->res->headers->content_disposition("attachment; filename=$action.yaml");
1718
$c->res->headers->content_type('application/yaml');
1819
$c->stash(format => "text");

0 commit comments

Comments
 (0)