Skip to content

Commit

Permalink
Mojo::Template documentation tweaks
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Oct 19, 2012
1 parent 1655599 commit 20a5753
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
10 changes: 5 additions & 5 deletions lib/Mojo/Template.pm
Expand Up @@ -498,7 +498,7 @@ Keyword indicating the start of a capture block, defaults to C<begin>.
my $code = $mt->code;
$mt = $mt->code($code);
Template code.
Perl code for template.
=head2 C<comment_mark>
Expand Down Expand Up @@ -649,20 +649,20 @@ Construct a new L<Mojo::Template> object.
$mt = $mt->build;
Build template.
Build Perl code from tree.
=head2 C<compile>
my $exception = $mt->compile;
Compile template.
Compile Perl code for template.
=head2 C<interpret>
my $output = $mt->interpret;
my $output = $mt->interpret(@args);
Interpret template.
Interpret compiled template code.
# Reuse template
say $mt->render('Hello <%= $_[0] %>!', 'Bender');
Expand All @@ -673,7 +673,7 @@ Interpret template.
$mt = $mt->parse($template);
Parse template.
Parse template into tree.
=head2 C<render>
Expand Down
2 changes: 1 addition & 1 deletion lib/Mojolicious/Plugin/EPRenderer.pm
Expand Up @@ -28,7 +28,7 @@ sub register {
my $mt = Mojo::Template->new($template);

# Be a bit more relaxed for helpers
my $prepend = q[my $self = shift; Scalar::Util::weaken $self;]
my $prepend = 'my $self = shift; Scalar::Util::weaken $self;'
. q[no strict 'refs'; no warnings 'redefine';];

# Helpers
Expand Down

0 comments on commit 20a5753

Please sign in to comment.