diff options
author | groditi <groditi@03d0b0b2-0e1a-0410-a411-fdb2f4bd65d7> | 2008-01-21 22:08:47 +0000 |
---|---|---|
committer | groditi <groditi@03d0b0b2-0e1a-0410-a411-fdb2f4bd65d7> | 2008-01-21 22:08:47 +0000 |
commit | cb92a3a388a813d1309757155a4b7750eb9f5504 (patch) | |
tree | a149a0d6e129517b44ab6d41a0d89ff101be91c8 /lib/Reaction/UI/LayoutSet | |
parent | c6ea0238337f4b071be1670e01cfa0a6467db101 (diff) | |
download | reaction-cb92a3a388a813d1309757155a4b7750eb9f5504.tar.gz reaction-cb92a3a388a813d1309757155a4b7750eb9f5504.zip |
add a default 404 and 403 action, use the 404 on collection controller, make html source less ugly by eliminating unnecessary whitespace
Diffstat (limited to 'lib/Reaction/UI/LayoutSet')
-rw-r--r-- | lib/Reaction/UI/LayoutSet/TT.pm | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/lib/Reaction/UI/LayoutSet/TT.pm b/lib/Reaction/UI/LayoutSet/TT.pm index 2046c41..c131bdb 100644 --- a/lib/Reaction/UI/LayoutSet/TT.pm +++ b/lib/Reaction/UI/LayoutSet/TT.pm @@ -27,12 +27,11 @@ class TT is LayoutSet, which { my $name = $self->name; $name =~ s/\//__/g; #slashes are not happy here... my $layouts = $self->layouts; - my $tt_source = qq{[% VIEW ${name};\n\n}. - join("\n\n", - map { - qq{BLOCK $_; -%]\n}.$layouts->{$_}.qq{\n[% END;}; - } keys %$layouts - ).qq{\nEND; # End view\ndata.view = ${name};\n %]}; + + my $tt_source = join("\n", "[%- VIEW ${name};", + (map {("BLOCK $_; -%]" . $layouts->{$_} ."[%- END;") } keys %$layouts), + "END; # End view\ndata.view = ${name}; -%]" ); + $tt_object->process(\$tt_source, $tt_args) || confess "Template processing error: ".$tt_object->error ." processing:\n${tt_source}"; |