atmosx-nwws-parser 1.0.183 → 1.0.184
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.
- package/package.json +1 -1
- package/src/events.js +4 -4
package/package.json
CHANGED
package/src/events.js
CHANGED
|
@@ -172,11 +172,11 @@ class NoaaWeatherWireServiceEvents {
|
|
|
172
172
|
id: `Wire-${vtec.tracking}`,
|
|
173
173
|
tracking: vtec.tracking,
|
|
174
174
|
action: vtec.status,
|
|
175
|
-
history: [{description: getDescription, action: vtec.status, issued:
|
|
175
|
+
history: [{description: getDescription, action: vtec.status, issued: getTempIssue}],
|
|
176
176
|
properties: {
|
|
177
177
|
areaDesc: mUgc.locations.join(`; `) || `N/A`,
|
|
178
178
|
expires: new Date(vtec.expires) == `Invalid Date` ? new Date(9999, 0, 1) : new Date(vtec.expires),
|
|
179
|
-
sent: new Date(vtec.issued) == `Invalid Date` ? getTempIssue
|
|
179
|
+
sent: new Date(vtec.issued) == `Invalid Date` ? getTempIssue : new Date(vtec.issued),
|
|
180
180
|
messageType: vtec.status,
|
|
181
181
|
event: vtec.event || `Unknown Event`,
|
|
182
182
|
sender: senderOffice,
|
|
@@ -231,13 +231,13 @@ class NoaaWeatherWireServiceEvents {
|
|
|
231
231
|
let senderOffice = loader.packages.mText.getOffice(msg) || `NWS`;
|
|
232
232
|
let getCoordinates = loader.packages.mText.getPolygonCoordinates(msg);
|
|
233
233
|
let getDescription = loader.packages.mText.getCleanDescription(msg, null);
|
|
234
|
-
let issuedDate = new Date(stanza.attributes.issue) == `Invalid Date` ? getTempIssue
|
|
234
|
+
let issuedDate = new Date(stanza.attributes.issue) == `Invalid Date` ? getTempIssue : new Date(stanza.attributes.issue);
|
|
235
235
|
let alert = {
|
|
236
236
|
hitch: `${new Date().getTime() - startTime}ms`,
|
|
237
237
|
id: `Wire-${defaultWMO ? defaultWMO[0] : `N/A`}-${mUgc.zones.join(`-`)}`,
|
|
238
238
|
tracking: `${defaultWMO ? defaultWMO[0] : `N/A`}-${mUgc.zones.join(`-`)}`,
|
|
239
239
|
action: `Issued`,
|
|
240
|
-
history: [{description: getDescription, action: `Issued`, issued:
|
|
240
|
+
history: [{description: getDescription, action: `Issued`, issued: getTempIssue}],
|
|
241
241
|
properties: {
|
|
242
242
|
areaDesc: mUgc.locations.join(`; `) || `N/A`,
|
|
243
243
|
// expieres is based off issuedDate
|