fix(protocol): return group join question and answer in admin settings

get_group_admin_settings reported the join mode correctly but left the
question and answer blank. The detail request now asks for those
strings the same way the official client does.

Closes #393
This commit is contained in:
DrSmoothl committed 2026-08-19 00:15:32 +08:00
1 parent b088ffaff0
commit 0a924634b2
4 files changed
+27 -3

No files matched your search

@@ -11,6 +11,7 @@ import type {
Oidb0x89a_0HistoryVisibility,
Oidb0x89a_0MemberPermission,
Oidb0xf16Req,
OidbGroupDetailRequest,
OidbGroupRequestAction,
OidbKickMember,
OidbLeaveGroup,
@@ -570,6 +571,11 @@ describe('apis/group-admin', () => {
'OidbSvcTrpcTcp.0x88d_0',
'OidbSvcTrpcTcp.0xef0_1',
]);
const detailReq = protobuf_decode<OidbBase<OidbGroupDetailRequest>>(
bridge.sendRawPacket.mock.calls.find((call) => call[0] === 'OidbSvcTrpcTcp.0x88d_0')![1],
);
expect(detailReq.body?.config?.flags?.question).toBe('');
expect(detailReq.body?.config?.flags?.answer).toBe('');
});
it('getAdminSettings treats omitted detail/ext zeros as the default values', async () => {