Piotr Czajkowski пре 3 година
родитељ
комит
a8f51c6f96
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      search.go

+ 1 - 1
search.go

@@ -108,7 +108,7 @@ func (app *Application) search(TMs []TM, text string) SearchResults {
 		}
 		defer resp.Body.Close()
 
-		if resp.StatusCode == 401 {
+		if resp.StatusCode == http.StatusUnauthorized {
 			time.Sleep(app.Delay)
 
 			status, err := app.login()