@turf/clone
Advanced tools
Comparing version 5.1.0 to 5.1.4
@@ -16,3 +16,3 @@ 'use strict'; | ||
function clone(geojson) { | ||
if (!geojson) { throw new Error('geojson is required'); } | ||
if (!geojson) throw new Error('geojson is required'); | ||
@@ -72,3 +72,3 @@ switch (geojson.type) { | ||
var cloned = {}; | ||
if (!properties) { return cloned; } | ||
if (!properties) return cloned; | ||
Object.keys(properties).forEach(function (key) { | ||
@@ -89,3 +89,3 @@ var value = properties[key]; | ||
} | ||
} else { cloned[key] = value; } | ||
} else cloned[key] = value; | ||
}); | ||
@@ -131,3 +131,3 @@ return cloned; | ||
var geom = {type: geometry.type}; | ||
if (geometry.bbox) { geom.bbox = geometry.bbox; } | ||
if (geometry.bbox) geom.bbox = geometry.bbox; | ||
@@ -134,0 +134,0 @@ if (geometry.type === 'GeometryCollection') { |
{ | ||
"name": "@turf/clone", | ||
"version": "5.1.0", | ||
"version": "5.1.4", | ||
"description": "turf clone module", | ||
"main": "main.js", | ||
"module": "main.mjs", | ||
"module": "main.es.js", | ||
"types": "index.d.ts", | ||
@@ -12,3 +12,3 @@ "files": [ | ||
"main.js", | ||
"main.mjs" | ||
"main.es.js" | ||
], | ||
@@ -18,2 +18,3 @@ "scripts": { | ||
"test": "node -r @std/esm test.js", | ||
"posttest": "node -r @std/esm ../../scripts/validate-es5-dependencies.js", | ||
"bench": "node -r @std/esm bench.js", | ||
@@ -41,10 +42,9 @@ "docs": "node ../../scripts/generate-readmes" | ||
"@std/esm": "*", | ||
"@turf/meta": "^5.1.0", | ||
"@turf/meta": "^5.1.4", | ||
"benchmark": "*", | ||
"rollup": "*", | ||
"rollup-plugin-buble": "*", | ||
"tape": "*" | ||
}, | ||
"dependencies": { | ||
"@turf/helpers": "^5.1.0" | ||
"@turf/helpers": "^5.1.4" | ||
}, | ||
@@ -51,0 +51,0 @@ "@std/esm": { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
5
11628
6
293
Updated@turf/helpers@^5.1.4