popup
This commit is contained in:
@@ -101,13 +101,14 @@ func (c *Client) GetWeatherData() (*WeatherData, error) {
|
||||
}
|
||||
|
||||
// Convert to our structure
|
||||
// OWM retourne wind_speed et gust en m/s — conversion en km/h
|
||||
weatherData := &WeatherData{
|
||||
Temperature: owmData.Main.Temp,
|
||||
FeelsLike: owmData.Main.FeelsLike,
|
||||
Humidity: owmData.Main.Humidity,
|
||||
Pressure: owmData.Main.Pressure,
|
||||
WindSpeed: owmData.Wind.Speed,
|
||||
WindGust: owmData.Wind.Gust,
|
||||
WindSpeed: owmData.Wind.Speed * 3.6,
|
||||
WindGust: owmData.Wind.Gust * 3.6,
|
||||
WindDeg: owmData.Wind.Deg,
|
||||
Clouds: owmData.Clouds.All,
|
||||
UpdatedAt: time.Unix(owmData.Dt, 0).Format(time.RFC3339),
|
||||
|
||||
Reference in New Issue
Block a user