FIX: Restore functionality of `custom-html` for now
This commit is contained in:
parent
bd1b7bd330
commit
852639e27a
|
@ -20,7 +20,15 @@ export function setCustomHTML(key, html) {
|
||||||
_customizations[key] = html;
|
_customizations[key] = html;
|
||||||
}
|
}
|
||||||
|
|
||||||
registerHelper('custom-html', function([id]) {
|
registerHelper('custom-html', function([id, contextString], hash, options, env) {
|
||||||
const html = getCustomHTML(id);
|
const html = getCustomHTML(id);
|
||||||
if (html) { return html; }
|
if (html) { return html; }
|
||||||
|
|
||||||
|
if (env) {
|
||||||
|
const target = (env || contextString);
|
||||||
|
const container = target.container || target.data.view.container;
|
||||||
|
if (container.lookup('template:' + id)) {
|
||||||
|
return env.helpers.partial.helperFunction.apply(this, arguments);
|
||||||
|
}
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in New Issue