Merge pull request #4620 from angusmcleod/fix/raw_templates_mobile_plugin

Resolve raw templates in 'javascripts/mobile' and 'javascripts' on mobile
This commit is contained in:
Robin Ward 2016-12-22 18:49:55 -05:00 committed by GitHub
commit d572db38e4
1 changed files with 3 additions and 1 deletions

View File

@ -2,7 +2,9 @@ import { getResolverOption } from 'discourse-common/resolver';
export function findRawTemplate(name) { export function findRawTemplate(name) {
if (getResolverOption('mobileView')) { if (getResolverOption('mobileView')) {
return Discourse.RAW_TEMPLATES[`mobile/${name}`] || return Discourse.RAW_TEMPLATES[`javascripts/mobile/${name}`] ||
Discourse.RAW_TEMPLATES[`javascripts/${name}`] ||
Discourse.RAW_TEMPLATES[`mobile/${name}`] ||
Discourse.RAW_TEMPLATES[name]; Discourse.RAW_TEMPLATES[name];
} }