Comparing version 0.32.9 to 0.32.10
@@ -263,6 +263,11 @@ "use strict"; | ||
else if (eventType === "child_added") { | ||
const data = getDb(util_1.join(path)); | ||
const snap = new index_1.SnapShot(util_1.join(path), { [data.id]: data }); | ||
const list = getDb(util_1.join(path)) || {}; | ||
// notify watchers | ||
callback(snap); | ||
Object.keys(list).forEach(key => { | ||
const data = lodash_get_1.default(list, key); | ||
if (data) { | ||
const snap = new index_1.SnapShot(util_1.join(path, key), { [key]: data }); | ||
callback(snap); | ||
} | ||
}); | ||
} | ||
@@ -269,0 +274,0 @@ } |
@@ -246,6 +246,11 @@ // tslint:disable:no-implicit-dependencies | ||
else if (eventType === "child_added") { | ||
const data = getDb(join(path)); | ||
const snap = new SnapShot(join(path), { [data.id]: data }); | ||
const list = getDb(join(path)) || {}; | ||
// notify watchers | ||
callback(snap); | ||
Object.keys(list).forEach(key => { | ||
const data = get(list, key); | ||
if (data) { | ||
const snap = new SnapShot(join(path, key), { [key]: data }); | ||
callback(snap); | ||
} | ||
}); | ||
} | ||
@@ -252,0 +257,0 @@ } |
{ | ||
"name": "firemock", | ||
"version": "0.32.9", | ||
"version": "0.32.10", | ||
"description": "firemock", | ||
@@ -5,0 +5,0 @@ "license": "MIT", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
382799
6740