mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-07-02 03:23:56 -07:00
refactor redux data model
This commit is contained in:
parent
ae1bc3da38
commit
0ff391491d
243 changed files with 5212 additions and 5963 deletions
|
|
@ -1,17 +1,16 @@
|
|||
import { create } from '@bufbuild/protobuf';
|
||||
import webClient from '../../WebClient';
|
||||
import { WebClient } from '../../WebClient';
|
||||
|
||||
import { ModeratorPersistence } from '../../persistence';
|
||||
import { Data } from '@app/types';
|
||||
|
||||
export function getWarnList(modName: string, userName: string, userClientid: string): void {
|
||||
webClient.protobuf.sendModeratorCommand(
|
||||
WebClient.instance.protobuf.sendModeratorCommand(
|
||||
Data.Command_GetWarnList_ext,
|
||||
create(Data.Command_GetWarnListSchema, { modName, userName, userClientid }),
|
||||
{
|
||||
responseExt: Data.Response_WarnList_ext,
|
||||
onSuccess: (response) => {
|
||||
ModeratorPersistence.warnListOptions([response]);
|
||||
WebClient.instance.response.moderator.warnListOptions([response]);
|
||||
},
|
||||
}
|
||||
);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue