fix bond post logic

This commit is contained in:
Grant Limberg 2023-04-26 17:07:22 -07:00
parent 42ab81906b
commit 0eecb8a8a0
No known key found for this signature in database
GPG key ID: 8F2F97D3BE8D7735

View file

@ -1632,15 +1632,17 @@ public:
std::vector<World> moons(_node->moons());
const uint64_t id = Utils::hexStrToU64(input.str().c_str());
bool found = false;
auto out = json::object();
for(std::vector<World>::const_iterator m(moons.begin());m!=moons.end();++m) {
if (m->id() == id) {
_moonToJson(out,*m);
found = true;
break;
}
}
if (seed != 0) {
if (!found && seed != 0) {
char tmp[64];
OSUtils::ztsnprintf(tmp,sizeof(tmp),"%.16llx",id);
out["id"] = tmp;