Commit 8aad35fa authored by Shawn M Moore's avatar Shawn M Moore
Browse files

Move the ref-ification into _ParseContentFull since it's a Text::Template-ism

parent 271d8cdd
......@@ -402,13 +402,6 @@ sub _ParseContent {
$args{'loc'} = sub { $self->loc(@_) };
}
foreach my $key ( keys %args ) {
next unless ref $args{ $key };
next if ref $args{ $key } =~ /^(ARRAY|HASH|SCALAR|CODE)$/;
my $val = $args{ $key };
$args{ $key } = \$val;
}
if ($self->Type eq 'Full') {
return $self->_ParseContentFull(
Content => $content,
......@@ -432,6 +425,13 @@ sub _ParseContentFull {
@_,
);
foreach my $key ( keys %{ $args{TemplateArgs} } ) {
my $val = $args{TemplateArgs}{ $key };
next unless ref $val;
next if ref $val =~ /^(ARRAY|HASH|SCALAR|CODE)$/;
$args{TemplateArgs}{ $key } = \$val;
}
my $template = Text::Template->new(
TYPE => 'STRING',
SOURCE => $args{Content},
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment