Skip to content

Commit ca1dff9

Browse files
committed
fix naming
1 parent 647497e commit ca1dff9

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

src/client.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -179,8 +179,8 @@ import {
179179
QuerySegmentTargetsFilter,
180180
SortParam,
181181
GetMessageOptions,
182-
BlockUserResponse,
183-
GetBlockedUsersResponse,
182+
BlockUserAPIResponse,
183+
GetBlockedUsersAPIResponse,
184184
QueryVotesFilters,
185185
VoteSort,
186186
CreatePollAPIResponse,
@@ -2191,19 +2191,19 @@ export class StreamChat<StreamChatGenerics extends ExtendableGenerics = DefaultG
21912191
});
21922192
}
21932193
async blockUser(blockedUserID: string, user_id?: string) {
2194-
return await this.post<BlockUserResponse>(this.baseURL + '/users/block', {
2194+
return await this.post<BlockUserAPIResponse>(this.baseURL + '/users/block', {
21952195
blocked_user_id: blockedUserID,
21962196
...(user_id ? { user_id } : {}),
21972197
});
21982198
}
21992199

22002200
async getBlockedUsers(user_id?: string) {
2201-
return await this.get<GetBlockedUsersResponse>(this.baseURL + '/users/block', {
2201+
return await this.get<GetBlockedUsersAPIResponse>(this.baseURL + '/users/block', {
22022202
...(user_id ? { user_id } : {}),
22032203
});
22042204
}
22052205
async unBlockUser(blockedUserID: string, userID?: string) {
2206-
return await this.post<StreamChatGenerics>(this.baseURL + '/users/unblock', {
2206+
return await this.post<APIResponse>(this.baseURL + '/users/unblock', {
22072207
blocked_user_id: blockedUserID,
22082208
...(userID ? { user_id: userID } : {}),
22092209
});

src/types.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -697,13 +697,13 @@ export type MuteUserResponse<StreamChatGenerics extends ExtendableGenerics = Def
697697
own_user?: OwnUserResponse<StreamChatGenerics>;
698698
};
699699

700-
export type BlockUserResponse = APIResponse & {
700+
export type BlockUserAPIResponse = APIResponse & {
701701
blocked_by_user_id: string;
702702
blocked_user_id: string;
703703
created_at: string;
704704
};
705705

706-
export type GetBlockedUsersResponse = APIResponse & {
706+
export type GetBlockedUsersAPIResponse = APIResponse & {
707707
blocks: BlockedUser[];
708708
};
709709
export type BlockedUser = APIResponse & {

0 commit comments

Comments
 (0)