Skip to content

Commit

Permalink
fix: cinfo json output error (#389)
Browse files Browse the repository at this point in the history
  • Loading branch information
1daidai1 authored Dec 9, 2024
1 parent 5be1b79 commit d85f41a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/CraneCtld/CranedMetaContainer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -426,8 +426,10 @@ crane::grpc::QueryClusterInfoReply CranedMetaContainer::QueryClusterInfo(
};

if (request.filter_craned_control_states().empty() ||
request.filter_craned_resource_states().empty())
request.filter_craned_resource_states().empty()) {
reply.set_ok(true);
return reply;
}

const int control_state_num = crane::grpc::CranedControlState_ARRAYSIZE;
bool control_filters[control_state_num] = {false};
Expand Down Expand Up @@ -532,6 +534,7 @@ crane::grpc::QueryClusterInfoReply CranedMetaContainer::QueryClusterInfo(
}
});

reply.set_ok(true);
return reply;
}

Expand Down

0 comments on commit d85f41a

Please sign in to comment.