chore: add rest api return (#3850)

This commit is contained in:
Alex Junior 2022-03-07 11:08:45 -03:00 committed by GitHub
parent 1ef9f57f3d
commit ec7538abfd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 3 deletions

View File

@ -57,4 +57,7 @@ export type ChatEndpoints = {
'chat.react': { 'chat.react': {
POST: (params: { emoji: string; messageId: string }) => void; POST: (params: { emoji: string; messageId: string }) => void;
}; };
'chat.ignoreUser': {
GET: (params: { rid: string; userId: string; ignore: boolean }) => {};
};
}; };

View File

@ -518,10 +518,8 @@ export const removeUserFromRoom = ({ roomId, t, userId }: { roomId: string; t: R
// RC 0.48.0 // RC 0.48.0
sdk.post(`${roomTypeToApiType(t)}.kick`, { roomId, userId }); sdk.post(`${roomTypeToApiType(t)}.kick`, { roomId, userId });
export const ignoreUser = ({ rid, userId, ignore }: { rid: string; userId: string; ignore: boolean }): any => export const ignoreUser = ({ rid, userId, ignore }: { rid: string; userId: string; ignore: boolean }) =>
// RC 0.64.0 // RC 0.64.0
// TODO: missing definitions from server
// @ts-ignore
sdk.get('chat.ignoreUser', { rid, userId, ignore }); sdk.get('chat.ignoreUser', { rid, userId, ignore });
export const toggleArchiveRoom = (roomId: string, t: SubscriptionType, archive: boolean) => { export const toggleArchiveRoom = (roomId: string, t: SubscriptionType, archive: boolean) => {