mirror of
https://github.com/netbymatt/ws4kp.git
synced 2026-04-17 00:59:29 -07:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c07ebe8bdd | ||
|
|
a41b0da196 |
4
package-lock.json
generated
4
package-lock.json
generated
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "ws4kp",
|
"name": "ws4kp",
|
||||||
"version": "6.5.8",
|
"version": "6.5.9",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "ws4kp",
|
"name": "ws4kp",
|
||||||
"version": "6.5.8",
|
"version": "6.5.9",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"dotenv": "^17.0.1",
|
"dotenv": "^17.0.1",
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "ws4kp",
|
"name": "ws4kp",
|
||||||
"version": "6.5.8",
|
"version": "6.5.9",
|
||||||
"description": "Welcome to the WeatherStar 4000+ project page!",
|
"description": "Welcome to the WeatherStar 4000+ project page!",
|
||||||
"main": "index.mjs",
|
"main": "index.mjs",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
|
|||||||
@@ -102,9 +102,8 @@ class CurrentWeather extends WeatherDisplay {
|
|||||||
});
|
});
|
||||||
|
|
||||||
// copy enhanced data and restore the timestamp if it was overwritten by older data from mapclick
|
// copy enhanced data and restore the timestamp if it was overwritten by older data from mapclick
|
||||||
const { timestamp } = candidateObservation.features[0].properties;
|
|
||||||
candidateObservation.features[0].properties = enhancedResult.data;
|
candidateObservation.features[0].properties = enhancedResult.data;
|
||||||
candidateObservation.features[0].properties.timestamp = timestamp;
|
|
||||||
|
|
||||||
const { missingFields } = enhancedResult;
|
const { missingFields } = enhancedResult;
|
||||||
const missingRequired = missingFields.filter((fieldName) => {
|
const missingRequired = missingFields.filter((fieldName) => {
|
||||||
|
|||||||
@@ -650,7 +650,7 @@ export const enhanceObservationWithMapClick = async (observationData, options =
|
|||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
data: mapClickProps,
|
data: { ...mapClickProps, timestamp: observationData.timestamp },
|
||||||
wasImproved: true,
|
wasImproved: true,
|
||||||
improvements,
|
improvements,
|
||||||
missingFields: [...mapClickMissingRequired, ...mapClickMissingOptional],
|
missingFields: [...mapClickMissingRequired, ...mapClickMissingOptional],
|
||||||
|
|||||||
Reference in New Issue
Block a user