--- trunk/lib/Frey/Pod.pm 2008/11/16 16:36:53 358 +++ trunk/lib/Frey/Pod.pm 2008/12/02 22:16:17 694 @@ -20,12 +20,12 @@ use Data::Dump qw/dump/; use Pod::Find qw/pod_where/; -sub markup { +sub as_markup { my $self = shift; my $class = $self->class; use Pod::Simple::HTML; my $path = pod_where( { -inc => 1 }, $class ); - return $self->error( "Can't find pod for $class" ) unless $path; + return $self->error( "Can't find pod for $class\n" ) unless $path; my $pod = read_file( $path ); my $converter = Pod::Simple::HTML->new(); my $body; @@ -36,16 +36,14 @@ $body =~ s{\s*\s*$}{}; $body =~ s!%3A%3A!::!g; # $body =~ s{]*)>}{}g; - $body =~ s{]*)>([^<]+)<([^>]+)>}{$4<$5>◊<$5>}g; + $body =~ s{]*)>([^<]+)<([^>]+)>}{$4<$5>◊<$5>}g; $body =~ s!\n\t!; $body =~ s!

!!; $body =~ s!__index__!index!g; - return { - title => $class, - body => $body, - } if wantarray; + $self->title( $class ); return $body; + } 1;