Open sentrychris opened 1 year ago
The main star should have BodyID=0, but in this case BodyID is null
.
if(!array_key_exists('id64', $currentBodyData) || $currentBodyData['id64'] != $message['BodyID'])
That !=
probably should be !==
php > var_dump(0 != null);
bool(false)
php > var_dump(0 !== null);
bool(true)
Forgive me if this is the wrong place for this kind of issue. I'm building a personal tool using data from EDSM, primarily just for educational purposes, however while requesting system bodies from EDSM via the API, I encountered a celestial body that doesn't have an id64 value.
Here is the particular celestial body in the response from
https://www.edsm.net/api-system-v1/bodies?systemName=Trappist-1
:Based on Spansh's data, I assume it should be the same as the system:
5364950911832
.