Bugzilla – Attachment 59824 Details for
Bug 18036
Improve test coverage for themelanguage
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Proof that all 4 cases are triggered.
Proof-that-all-4-cases-are-triggered.patch (text/plain), 1.18 KB, created by
Mark Tompsett
on 2017-02-02 19:19:58 UTC
(
hide
)
Description:
Proof that all 4 cases are triggered.
Filename:
MIME Type:
Creator:
Mark Tompsett
Created:
2017-02-02 19:19:58 UTC
Size:
1.18 KB
patch
obsolete
>From 8b96cfb0de916a57a13ad1aecb1dcdfe2d159018 Mon Sep 17 00:00:00 2001 >From: Mark Tompsett <mtompset@hotmail.com> >Date: Thu, 2 Feb 2017 12:05:05 -0500 >Subject: [PATCH] Proof that all 4 cases are triggered. > >https://bugs.koha-community.org/show_bug.cgi?id=18036 >--- > C4/Templates.pm | 4 ++++ > 1 file changed, 4 insertions(+) > >diff --git a/C4/Templates.pm b/C4/Templates.pm >index 10d0283..3415da1 100644 >--- a/C4/Templates.pm >+++ b/C4/Templates.pm >@@ -256,19 +256,23 @@ sub themelanguage { > my $where = $tmpl =~ /xsl$/ ? 'xslt' : 'modules'; > for my $theme (@themes) { > if ( -e "$htdocs/$theme/$lang/$where/$tmpl" ) { >+print STDERR "CASE 1"; > return ( $theme, $lang, [ uniq(@themes) ] ); > } > } > # Otherwise return theme/'en', last resort fallback/'en' > for my $theme (@themes) { > if ( -e "$htdocs/$theme/en/$where/$tmpl" ) { >+print STDERR "CASE 2"; > return ( $theme, 'en', [ uniq(@themes) ] ); > } > } > # tmpl is a full path, so this is a template for a plugin > if ( $tmpl =~ /^\// && -e $tmpl ) { >+print STDERR "CASE 3"; > return ( $themes[0], $lang, [ uniq(@themes) ] ); > } >+print STDERR "CASE 4"; > } > > >-- >2.1.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 18036
:
59767
|
59818
|
59819
|
59820
|
59821
|
59822
|
59823
|
59824
|
59825
|
59838
|
59839
|
59843
|
59844
|
59845
|
60351
|
60352
|
60353