diff options
author | Evgeny Kuznetsov <evgeny@kuznetsov.md> | 2020-01-27 19:44:58 +0300 |
---|---|---|
committer | Evgeny Kuznetsov <evgeny@kuznetsov.md> | 2020-01-27 19:44:58 +0300 |
commit | 3f683db50e2083550a38d9414d95b7f766a00531 (patch) | |
tree | d5d1090e337d4bb38d384f8f0fd1d398e9e6ff27 /main.go | |
parent | f531d45b0686e3941621647160062c5c8cc07970 (diff) | |
download | radiorus-rss-3f683db50e2083550a38d9414d95b7f766a00531.tar.gz radiorus-rss-3f683db50e2083550a38d9414d95b7f766a00531.zip |
remove unnecessary global err
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -51,7 +51,6 @@ var ( Created: time.Now(), } outputPath, programNumber string - err error ) func main() { @@ -94,10 +93,11 @@ func main() { dateBytes := episodeDateRe.FindSubmatch(episode) var date [5]int for i, b := range dateBytes[1:] { - date[i], err = strconv.Atoi(string(b)) + d, err := strconv.Atoi(string(b)) if err != nil { log.Fatal(err) } + date[i] = d } moscow := time.FixedZone("Moscow Time", int((3 * time.Hour).Seconds())) episodeDate := time.Date(date[2], time.Month(date[1]), date[0], date[3], date[4], 0, 0, moscow) |