Skip to content

Commit

Permalink
Added entity decoding for TOC generation titles.
Browse files Browse the repository at this point in the history
  • Loading branch information
chromatic committed Mar 27, 2012
1 parent a9520eb commit d090512
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/Pod/PseudoPod/Book/Command/buildepub.pm
Expand Up @@ -10,6 +10,7 @@ use autodie;
use EBook::EPUB;
use File::Slurp;
use File::Basename;
use HTML::Entities;
use File::Spec::Functions qw( catfile catdir splitpath );

sub execute
Expand All @@ -35,7 +36,8 @@ sub get_toc
my ($level, $identifier, $label) = ($1, $2, $3);
$label =~ s/<[^>]+>//g;
$label =~ s/&amp;/&/g;
push @toc, [ $level, $identifier, $label, $chapter ];
push @toc,
[ $level, $identifier, decode_entities($label), $chapter ];
}
}

Expand Down

0 comments on commit d090512

Please sign in to comment.