* missing variable assignment because LoginWithExistingCookies() returns two values (bool, error) as I see there is only an Error when the Login process fails. I don't think that we need to return the bool here.
@@ -99,7 +99,7 @@ func PageContentHandler(c echo.Context) error {
// LoginHandler ...
func LoginHandler(c echo.Context) error {
bot := c.Get("bot").(*OGame)
- if err := bot.LoginWithExistingCookies(); err != nil {
+ if _, err := bot.LoginWithExistingCookies(); err != nil {
if err == ErrBadCredentials {
return c.JSON(http.StatusBadRequest, ErrorResp(400, err.Error()))
}
