mirror of
https://github.com/EQEmu/Server.git
synced 2026-02-20 21:02:26 +00:00
Add error handler so that calls aren't made when zone isn't booted
This commit is contained in:
parent
cbfd02b9ff
commit
81e511df13
@ -654,6 +654,11 @@ void EQEmuApiZoneDataService::get(Json::Value &response, const std::vector<std::
|
||||
{
|
||||
std::string method = args[0];
|
||||
|
||||
if (!zone->IsLoaded()) {
|
||||
response["error"] = "Zone must be loaded to invoke calls";
|
||||
return;
|
||||
}
|
||||
|
||||
if (method == "get_npc_list_detail") {
|
||||
callGetNpcListDetail(response);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user