diff --git a/turms-service/src/main/java/im/turms/service/domain/group/repository/GroupMemberRepository.java b/turms-service/src/main/java/im/turms/service/domain/group/repository/GroupMemberRepository.java index 7739bad6c6..844a60ecd9 100644 --- a/turms-service/src/main/java/im/turms/service/domain/group/repository/GroupMemberRepository.java +++ b/turms-service/src/main/java/im/turms/service/domain/group/repository/GroupMemberRepository.java @@ -204,10 +204,12 @@ public Flux findUserJoinedGroupIds(Long userId) { } public Flux findUsersJoinedGroupIds( + @Nullable Set groupIds, @NotEmpty Set userIds, @Nullable Integer page, @Nullable Integer size) { - Filter filter = Filter.newBuilder(1) + Filter filter = Filter.newBuilder(2) + .inIfNotNull(GroupMember.Fields.ID_GROUP_ID, groupIds) .inIfNotNull(GroupMember.Fields.ID_USER_ID, userIds); QueryOptions options = QueryOptions.newBuilder(3) .paginateIfNotNull(page, size)