Fix incorrect response schema
This commit is contained in:
parent
8e9691943a
commit
ab9447591b
|
@ -215,7 +215,9 @@ func (s Server) fetchCategory(organizer, event string, item uint) string {
|
|||
|
||||
decoder = json.NewDecoder(resp.Body)
|
||||
itemCategory := struct{
|
||||
Name string
|
||||
Name struct{
|
||||
German string `json:"de-informal"`
|
||||
}
|
||||
}{}
|
||||
|
||||
err = decoder.Decode(&itemCategory)
|
||||
|
@ -223,7 +225,7 @@ func (s Server) fetchCategory(organizer, event string, item uint) string {
|
|||
return ""
|
||||
}
|
||||
|
||||
return itemCategory.Name
|
||||
return itemCategory.Name.German
|
||||
}
|
||||
|
||||
func parsePrice(price string) (euros uint64, cents uint64, err error) {
|
||||
|
|
Loading…
Reference in New Issue