Skip to content

Commit

Permalink
wrapper.Celestial/wrapper.Planet/wrapper.Moon/ogame.Planet/ogame.Moon…
Browse files Browse the repository at this point in the history
… ... all implement ogame.Celestial
  • Loading branch information
alaingilbert committed Aug 21, 2022
1 parent 2d5ae3a commit 18ba99c
Showing 1 changed file with 1 addition and 10 deletions.
11 changes: 1 addition & 10 deletions pkg/extractor/v6/extracts.go
Original file line number Diff line number Diff line change
Expand Up @@ -181,16 +181,7 @@ func extractMoonFromDoc(doc *goquery.Document, v any) (ogame.Moon, error) {

func extractCelestialFromDoc(doc *goquery.Document, v any) (ogame.Celestial, error) {
switch vv := v.(type) {
// TODO: fix this
//case wrapper.Celestial:
// return extractCelestialByIDFromDoc(doc, vv.GetID())
//case ogame2.Planet:
// return extractCelestialByIDFromDoc(doc, vv.GetID())
//case ogame2.Moon:
//return extractCelestialByIDFromDoc(doc, vv.GetID())
case ogame.Planet:
return extractCelestialByIDFromDoc(doc, vv.GetID())
case ogame.Moon:
case ogame.Celestial:
return extractCelestialByIDFromDoc(doc, vv.GetID())
case ogame.PlanetID:
return extractCelestialByIDFromDoc(doc, vv.Celestial())
Expand Down

0 comments on commit 18ba99c

Please sign in to comment.