Merge pull request #2 from darknesto/master

Remove duplicated deferred call
This commit is contained in:
Christopher Herrera 2014-09-26 16:39:11 -04:00
commit 20b1904f2d

View file

@ -129,7 +129,7 @@ func GetMovieByTitle(title string, year string) (*MovieResult, error) {
r := new(MovieResult)
err = json.NewDecoder(resp.Body).Decode(r)
defer resp.Body.Close()
if err != nil {
return nil, err
}
@ -149,7 +149,7 @@ func GetMovieByImdbId(id string) (*MovieResult, error) {
r := new(MovieResult)
err = json.NewDecoder(resp.Body).Decode(r)
defer resp.Body.Close()
if err != nil {
return nil, err
}