mirror of
https://github.com/pawelmalak/flame.git
synced 2025-07-19 11:39:36 +02:00
f
This commit is contained in:
parent
408ed1e317
commit
99d3767a5b
1 changed files with 2 additions and 4 deletions
|
@ -26,16 +26,14 @@ const getExternalWeather = async () => {
|
||||||
isDay: Boolean(cursor.is_day),
|
isDay: Boolean(cursor.is_day),
|
||||||
cloud: cursor.cloud_cover,
|
cloud: cursor.cloud_cover,
|
||||||
conditionText: '',
|
conditionText: '',
|
||||||
conditionCode: 1, // cursor.weathercode
|
conditionCode: cursor.weathercode,
|
||||||
humidity: cursor.relative_humidity_2m,
|
humidity: cursor.relative_humidity_2m,
|
||||||
windK: cursor.wind_speed_10m,
|
windK: cursor.wind_speed_10m,
|
||||||
windM: cursor.wind_speed_10m,
|
windM: cursor.wind_speed_10m,
|
||||||
});
|
});
|
||||||
return weatherData;
|
return weatherData;
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
// TODO to update
|
throw new Error('External API request failed');
|
||||||
throw new Error(err);
|
|
||||||
//throw new Error('External API request failed');
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue