Skip to content

Commit

Permalink
Don't trim undefined strings
Browse files Browse the repository at this point in the history
  • Loading branch information
benkasminbullock committed Jul 6, 2019
1 parent 2102045 commit 4632d77
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions lib/Image/CairoSVG.pm
Expand Up @@ -562,9 +562,13 @@ sub do_svg_attr
}
}
my $fill = $attr{fill};
$fill =~ s/^\s+|\s+$//g;
if ($fill) {
$fill =~ s/^\s+|\s+$//g;
}
my $stroke = $attr{stroke};
$stroke =~ s/^\s+|\s+$//g;
if ($stroke) {
$stroke =~ s/^\s+|\s+$//g;
}
my $cr = $self->{cr};
my $stroke_width = $attr{"stroke-width"};
if ($stroke_width) {
Expand Down

0 comments on commit 4632d77

Please sign in to comment.