diff options
author | Matthew Somerville <matthew@mysociety.org> | 2012-02-23 13:26:51 +0000 |
---|---|---|
committer | Matthew Somerville <matthew@mysociety.org> | 2012-02-23 13:26:51 +0000 |
commit | 2853ca4a6290ad46e9ae283d2d85f0ef958dbcac (patch) | |
tree | ff11c4510d16da93e0c908c7f14e0af9e96e4517 /perllib/FixMyStreet/App.pm | |
parent | a3b774254a987c767dae890ed076e685dff4c561 (diff) |
Only need to set additional_template_paths if other variables are being set, otherwise it comes in automatically from the stash.
Diffstat (limited to 'perllib/FixMyStreet/App.pm')
-rw-r--r-- | perllib/FixMyStreet/App.pm | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/perllib/FixMyStreet/App.pm b/perllib/FixMyStreet/App.pm index d39ae1415..18cad6b89 100644 --- a/perllib/FixMyStreet/App.pm +++ b/perllib/FixMyStreet/App.pm @@ -411,9 +411,8 @@ call), use this method. sub render_fragment { my ($c, $template, $vars) = @_; - $vars ||= {}; $vars->{additional_template_paths} = [ $c->cobrand->path_to_web_templates->stringify ] - unless $c->cobrand->is_default; + if $vars && !$c->cobrand->is_default; $c->view('Web')->render($c, $template, $vars); } |