fix: remove memory leak

This commit is contained in:
Adrien Waksberg 2019-08-24 19:33:40 +02:00
parent 31075ef579
commit f366938d55
2 changed files with 5 additions and 0 deletions

View file

@ -7,6 +7,10 @@ Which is based on [Keep A Changelog](http://keepachangelog.com/)
## Unreleased
### Fixed
- remove memory leak
## v1.0.1 - 2019-08-22
### Added

View file

@ -62,6 +62,7 @@ type WeatherData struct {
// FetchData from OpenWeatherMap API
func (w *Weather) FetchData() {
w.WeatherDatas = []WeatherData{}
for _, city := range w.Config.Cities {
resp, err := http.Get(
fmt.Sprintf(