@nativescript/firebase-core
Advanced tools
Comparing version 2.4.4 to 2.5.0
{ | ||
"name": "@nativescript/firebase-core", | ||
"version": "2.4.4", | ||
"version": "2.5.0", | ||
"description": "NativeScript Firebase - Core", | ||
@@ -5,0 +5,0 @@ "main": "index", |
10
utils.js
@@ -34,9 +34,7 @@ function numberHasDecimals(item) { | ||
if (Array.isArray(data)) { | ||
return NSArray.arrayWithArray(data.map(serialize)); | ||
return NSArray.arrayWithArray(data.map((el) => serialize(el, wrapPrimitives)).filter((el) => el !== null)); | ||
} | ||
let node = {}; | ||
Object.keys(data).forEach(function (key) { | ||
let value = data[key]; | ||
node[key] = serialize(value, wrapPrimitives); | ||
}); | ||
const node = Object.fromEntries(Object.entries(data) | ||
.map(([key, value]) => [key, serialize(value, wrapPrimitives)]) | ||
.filter(([, value]) => value !== null)); | ||
return NSDictionary.dictionaryWithDictionary(node); | ||
@@ -43,0 +41,0 @@ } |
Sorry, the diff of this file is not supported yet
163120
2046