From: Max Kanat-Alexander Date: Thu, 6 May 2010 02:14:04 +0000 (-0700) Subject: Bug 562551: Allow template-only extensions to work X-Git-Tag: bugzilla-3.7.1~101 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9500ea0126044d372fbd311966bfa077f9d135fe;p=thirdparty%2Fbugzilla.git Bug 562551: Allow template-only extensions to work r=mkanat, a=mkanat (module owner) --- diff --git a/Bugzilla/Install/Util.pm b/Bugzilla/Install/Util.pm index 7bafa93300..7779f6bda6 100644 --- a/Bugzilla/Install/Util.pm +++ b/Bugzilla/Install/Util.pm @@ -418,6 +418,18 @@ sub _template_base_directories { } } + # Extensions may also contain *only* templates, in which case they + # won't show up in extension_requirement_packages. + foreach my $path (_extension_paths()) { + next if !-d $path; + if (!-e "$path/Extension.pm" and !-e "$path/Config.pm" + and -d "$path/template") + { + push(@template_dirs, "$path/template"); + } + } + + push(@template_dirs, bz_locations()->{'templatedir'}); return \@template_dirs; }