fixed issue caused by using same name for defaults and overrides

master
Jonathan Stewmon 2011-12-19 16:37:16 -06:00 committed by indexzero
parent e0e070ab28
commit 2804b1fb37
1 changed files with 5 additions and 1 deletions

View File

@ -41,7 +41,11 @@ var Provider = exports.Provider = function (options) {
//
['defaults', 'overrides'].forEach(function (type) {
Provider.prototype[type] = function (options) {
return this.add('literal', options);
options = options || {};
if(!options.type) {
options.type = 'literal';
}
return this.add(type, options);
};
});