1
0
mirror of https://github.com/EDCD/EDMarketConnector.git synced 2025-04-17 17:42:20 +03:00

eddn: Fix capi_fcmaterials gameversion/build & add to CAPI commodity

* Erroneously used 'CAPI-commoodity' when it's 'CAPI-market' (name of the
  CAPI endpoint, not anything to do with EDDN schema names, and '-commodity'
  would also be wrong for that).
* Set `header` for (CAPI) `export_commodities()`.
This commit is contained in:
Athanasius 2022-11-22 17:37:15 +00:00
parent b31c8c0536
commit f6e2504216
No known key found for this signature in database
GPG Key ID: 772697E181BB2767

View File

@ -635,6 +635,7 @@ class EDDN:
self.send_message(data['commander']['name'], {
'$schemaRef': f'https://eddn.edcd.io/schemas/commodity/3{"/test" if is_beta else ""}',
'message': message,
'header': self.standard_header(game_version='CAPI-market', game_build='CAPI-market')
})
this.commodities = commodities
@ -1453,7 +1454,7 @@ class EDDN:
msg = {
'$schemaRef': f'https://eddn.edcd.io/schemas/fcmaterials_capi/1{"/test" if is_beta else ""}',
'message': entry,
'header': self.standard_header(game_version='CAPI-commodity', game_build='CAPI-commodity'),
'header': self.standard_header(game_version='CAPI-market', game_build='CAPI-market'),
}
this.eddn.send_message(data['commander']['name'], msg)