[fix] Only merge actual objects, not `null` values. Fixes #150.

master
indexzero 2015-09-20 01:02:59 -07:00
parent a3589fab95
commit 4b5030dbc2
1 changed files with 2 additions and 2 deletions

View File

@ -250,7 +250,7 @@ Provider.prototype.get = function (key, callback) {
response = value;
// Merge objects if necessary
if (typeof response === 'object' && !Array.isArray(response)) {
if (response && typeof response === 'object' && !Array.isArray(response)) {
mergeObjs.push(response);
response = undefined;
}
@ -262,7 +262,7 @@ Provider.prototype.get = function (key, callback) {
response = store.get(key);
// Merge objects if necessary
if (typeof response === 'object' && !Array.isArray(response)) {
if (response && typeof response === 'object' && !Array.isArray(response)) {
mergeObjs.push(response);
response = undefined;
}