From 45d0e68e1193c671233a5a515dd840f0d0b3820e Mon Sep 17 00:00:00 2001 From: Mark Perkins Date: Wed, 17 Aug 2016 14:00:00 +0100 Subject: [PATCH] Fix inconsistency in config key names for custom handlebars instances --- index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/index.js b/index.js index 2fd7b310..ea0738f6 100644 --- a/index.js +++ b/index.js @@ -24,7 +24,7 @@ module.exports = function helpers(groups, options) { } options = options || {}; - var hbs = options.handlebars || require('handlebars'); + var hbs = options.handlebars || options.hbs || require('handlebars'); define(module.exports, 'handlebars', hbs); @@ -47,7 +47,7 @@ module.exports = function helpers(groups, options) { forIn(lib, function(group, key) { define(module.exports, key, function(options) { options = options || {}; - var hbs = options.hbs || require('handlebars'); + var hbs = options.handlebars || options.hbs || require('handlebars'); define(module.exports, 'handlebars', hbs); hbs.registerHelper(group); return hbs.helpers;