@turf/center-mean
Advanced tools
Comparing version 5.1.0 to 5.1.5
@@ -33,3 +33,3 @@ 'use strict'; | ||
options = options || {}; | ||
if (!helpers.isObject(options)) { throw new Error('options is invalid'); } | ||
if (!helpers.isObject(options)) throw new Error('options is invalid'); | ||
var properties = options.properties; | ||
@@ -39,3 +39,3 @@ var weightTerm = options.weight; | ||
// Input validation | ||
if (!geojson) { throw new Error('geojson is required'); } | ||
if (!geojson) throw new Error('geojson is required'); | ||
@@ -48,3 +48,3 @@ var sumXs = 0; | ||
weight = (weight === undefined || weight === null) ? 1 : weight; | ||
if (!helpers.isNumber(weight)) { throw new Error('weight value must be a number for feature index ' + featureIndex); } | ||
if (!helpers.isNumber(weight)) throw new Error('weight value must be a number for feature index ' + featureIndex); | ||
weight = Number(weight); | ||
@@ -51,0 +51,0 @@ if (weight > 0) { |
{ | ||
"name": "@turf/center-mean", | ||
"version": "5.1.0", | ||
"version": "5.1.5", | ||
"description": "turf center-mean 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", | ||
@@ -46,4 +47,4 @@ "docs": "node ../../scripts/generate-readmes" | ||
"@std/esm": "*", | ||
"@turf/center": "^5.1.0", | ||
"@turf/truncate": "^5.1.0", | ||
"@turf/center": "^5.1.5", | ||
"@turf/truncate": "^5.1.5", | ||
"benchmark": "*", | ||
@@ -53,3 +54,2 @@ "glob": "*", | ||
"rollup": "*", | ||
"rollup-plugin-buble": "*", | ||
"tape": "*", | ||
@@ -59,5 +59,5 @@ "write-json-file": "*" | ||
"dependencies": { | ||
"@turf/bbox": "^5.1.0", | ||
"@turf/helpers": "^5.1.0", | ||
"@turf/meta": "^5.1.0" | ||
"@turf/bbox": "^5.1.5", | ||
"@turf/helpers": "^5.1.5", | ||
"@turf/meta": "^5.1.5" | ||
}, | ||
@@ -64,0 +64,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
11412
9
Updated@turf/bbox@^5.1.5
Updated@turf/helpers@^5.1.5
Updated@turf/meta@^5.1.5