summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorByron Jones <glob@mozilla.com>2014-09-25 19:39:39 +0200
committerByron Jones <glob@mozilla.com>2014-09-25 19:39:39 +0200
commit03c85287139860563b219ea85eb0583e7d40158b (patch)
tree23fe01767e09fbe5935dc926f32711b9035e6fa6
parente877bb3a0f67a24f4403e9e774838811d675b85e (diff)
downloadbugzilla-03c85287139860563b219ea85eb0583e7d40158b.tar.gz
bugzilla-03c85287139860563b219ea85eb0583e7d40158b.tar.xz
Bug 1072110: _concatenate_js assumes javascript_urls is an array
r=dkl,a=glob
-rw-r--r--Bugzilla/Template.pm3
-rw-r--r--template/en/default/attachment/diff-header.html.tmpl2
-rw-r--r--template/en/default/list/change-columns.html.tmpl2
3 files changed, 4 insertions, 3 deletions
diff --git a/Bugzilla/Template.pm b/Bugzilla/Template.pm
index c8f56d73d..e4c1bf460 100644
--- a/Bugzilla/Template.pm
+++ b/Bugzilla/Template.pm
@@ -546,7 +546,8 @@ sub _css_url_rewrite {
sub _concatenate_js {
return @_ unless CONCATENATE_ASSETS;
my ($sources) = @_;
- return [] unless $sources && ref($sources);
+ return [] unless $sources;
+ $sources = ref($sources) ? $sources : [ $sources ];
my %files =
map {
diff --git a/template/en/default/attachment/diff-header.html.tmpl b/template/en/default/attachment/diff-header.html.tmpl
index 94d2b9541..3d491fa4e 100644
--- a/template/en/default/attachment/diff-header.html.tmpl
+++ b/template/en/default/attachment/diff-header.html.tmpl
@@ -38,7 +38,7 @@ Interdiff of #[% oldid %] and #[% newid %] for [% terms.bug %] #[% bugid %]
[% bugsummary FILTER html %]
[% END %]
[% PROCESS global/header.html.tmpl doc_section = "using.html#patch-viewer"
- javascript_urls = "js/attachment.js"
+ javascript_urls = [ "js/attachment.js" ]
style_urls = ['skins/standard/bug.css'] %]
[% ELSE %]
<!DOCTYPE html>
diff --git a/template/en/default/list/change-columns.html.tmpl b/template/en/default/list/change-columns.html.tmpl
index 17d711eec..c0279803c 100644
--- a/template/en/default/list/change-columns.html.tmpl
+++ b/template/en/default/list/change-columns.html.tmpl
@@ -8,7 +8,7 @@
[% PROCESS global/header.html.tmpl
title = "Change Columns"
- javascript_urls = "js/change-columns.js"
+ javascript_urls = [ "js/change-columns.js" ]
onload = "initChangeColumns()"
%]