Add feels like weather support

master
RKBoss6 2025-06-28 14:19:29 -04:00 committed by GitHub
parent 7ace5bd00d
commit a118f8f6fd
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 3 additions and 2 deletions

View File

@ -180,6 +180,7 @@ E.on('notify',msg=>{
let weatherEvent = {
t: "weather",
temp: d.temp,
feels: d.feels,
hi: d.hi,
lo: d.lo,
hum: d.hum,
@ -192,7 +193,7 @@ E.on('notify',msg=>{
loc: d.loc
}
// Convert string fields to numbers for iOS weather shortcut
const numFields = ['code', 'wdir', 'temp', 'hi', 'lo', 'hum', 'wind', 'uv', 'rain'];
const numFields = ['code', 'wdir', 'temp','feels', 'hi', 'lo', 'hum', 'wind', 'uv', 'rain'];
numFields.forEach(field => {
if (weatherEvent[field] != null) weatherEvent[field] = +weatherEvent[field];
});