Skip to content

Commit

Permalink
fixed small Mojo::Template bug
Browse files Browse the repository at this point in the history
  • Loading branch information
kraih committed Jul 13, 2012
1 parent fad6cbc commit 4884be6
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 3 deletions.
3 changes: 3 additions & 0 deletions Changes
@@ -1,4 +1,7 @@

3.08 2012-07-14
- Fixed small Mojo::Template bug.

3.07 2012-07-13
- Improved template error messages for generator commands and config files.
- Improved documentation.
Expand Down
6 changes: 4 additions & 2 deletions lib/Mojo/Template.pm
Expand Up @@ -112,8 +112,10 @@ sub build {
$lines[0] .= "sub { my \$_M = ''; " . $self->prepend . "; do { $first";
$lines[-1] .= $self->append . "; \$_M; } };";

warn "-- Code (@{[$self->name]})\n", join("\n", @lines), "\n\n" if DEBUG;
return $self->code(join "\n", @lines)->tree([]);
# Code
my $code = join "\n", @lines;
warn "-- Code (@{[$self->name]})\n@{[encode 'UTF-8', $code]}\n\n" if DEBUG;
return $self->code($code)->tree([]);
}

sub compile {
Expand Down
2 changes: 1 addition & 1 deletion lib/Mojolicious.pm
Expand Up @@ -34,7 +34,7 @@ has static => sub { Mojolicious::Static->new };
has types => sub { Mojolicious::Types->new };

our $CODENAME = 'Rainbow';
our $VERSION = '3.07';
our $VERSION = '3.08';

# "These old doomsday devices are dangerously unstable.
# I'll rest easier not knowing where they are."
Expand Down

0 comments on commit 4884be6

Please sign in to comment.