fix build tech
@@ -3929,14 +3929,11 @@ func (b *OGame) build(celestialID CelestialID, id ID, nbr int64) error {
"cp": {strconv.FormatInt(int64(celestialID), 10)},
}
- // Techs don't have a token
- if !id.IsTech() {
token, err := getToken(b, page, celestialID)
if err != nil {
return err
}
vals.Add("token", token)
- }
if id.IsDefense() || id.IsShip() {
var maximumNbr int64 = 99999
@@ -3959,7 +3956,7 @@ func (b *OGame) build(celestialID CelestialID, id ID, nbr int64) error {
return err
}
- _, err := b.getPageContent(vals)
+ _, err = b.getPageContent(vals)
return err
}
