@saber-usa/node-common 1.7.9-alpha.1 → 1.7.9-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/package.json +1 -1
  2. package/src/udl.js +6 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@saber-usa/node-common",
3
- "version": "1.7.9-alpha.1",
3
+ "version": "1.7.9-alpha.2",
4
4
  "description": "Common node functions for Saber",
5
5
  "main": "src/index.js",
6
6
  "type": "module",
package/src/udl.js CHANGED
@@ -195,8 +195,12 @@ const enrichGeoLon = (npsOb, enrichedFields) => {
195
195
  );
196
196
  npsOb.GeoLon = geodetic.Longitude;
197
197
  npsOb.GeoLat = geodetic.Latitude;
198
- npsOb.GeoRange = slantRange;
199
- if (!npsOb.Range && !npsOb.GeoRange) enrichedFields.push("GeoRange");
198
+
199
+ if (typeof slantRange === "number" && !isNaN(slantRange)) {
200
+ if (!npsOb.Range && !npsOb.GeoRange) enrichedFields.push("GeoRange");
201
+ npsOb.GeoRange = slantRange;
202
+ }
203
+
200
204
  if (npsOb.GeoLon) enrichedFields.push("GeoLon");
201
205
  if (npsOb.GeoLat) enrichedFields.push("GeoLat");
202
206
  return enrichedFields;