mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-04-27 07:48:01 -07:00
Some checks failed
Build Desktop / Configure (push) Has been cancelled
Build Docker Image / amd64 & arm64 (push) Has been cancelled
Build Web / React (Node 16) (push) Has been cancelled
Build Web / React (Node lts/*) (push) Has been cancelled
Build Desktop / Debian 11 (push) Has been cancelled
Build Desktop / Debian 13 (push) Has been cancelled
Build Desktop / Debian 12 (push) Has been cancelled
Build Desktop / Fedora 43 (push) Has been cancelled
Build Desktop / Fedora 42 (push) Has been cancelled
Build Desktop / Servatrice_Debian 11 (push) Has been cancelled
Build Desktop / Ubuntu 24.04 (push) Has been cancelled
Build Desktop / Ubuntu 26.04 (push) Has been cancelled
Build Desktop / Ubuntu 22.04 (push) Has been cancelled
Build Desktop / Arch (push) Has been cancelled
Build Desktop / macOS 14 (push) Has been cancelled
Build Desktop / macOS 15 (push) Has been cancelled
Build Desktop / macOS 13 Intel (push) Has been cancelled
Build Desktop / macOS 15 Debug (push) Has been cancelled
Build Desktop / Windows 10 (push) Has been cancelled
46 lines
1.4 KiB
TypeScript
46 lines
1.4 KiB
TypeScript
import { ServerDispatch } from 'store';
|
|
import { BanHistoryItem, LogItem, WarnHistoryItem, WarnListItem } from 'types';
|
|
|
|
import NormalizeService from '../utils/NormalizeService';
|
|
|
|
export class ModeratorPersistence {
|
|
static banFromServer(userName: string): void {
|
|
ServerDispatch.banFromServer(userName);
|
|
}
|
|
|
|
static banHistory(userName: string, banHistory: BanHistoryItem[]): void {
|
|
ServerDispatch.banHistory(userName, banHistory);
|
|
}
|
|
|
|
static viewLogs(logs: LogItem[]): void {
|
|
ServerDispatch.viewLogs(NormalizeService.normalizeLogs(logs));
|
|
}
|
|
|
|
static warnHistory(userName: string, warnHistory: WarnHistoryItem[]): void {
|
|
ServerDispatch.warnHistory(userName, warnHistory);
|
|
}
|
|
|
|
static warnListOptions(warnList: WarnListItem[]): void {
|
|
ServerDispatch.warnListOptions(warnList);
|
|
}
|
|
|
|
static warnUser(userName: string): void {
|
|
ServerDispatch.warnUser(userName);
|
|
}
|
|
|
|
static grantReplayAccess(replayId: number, moderatorName: string): void {
|
|
ServerDispatch.grantReplayAccess(replayId, moderatorName);
|
|
}
|
|
|
|
static forceActivateUser(usernameToActivate: string, moderatorName: string): void {
|
|
ServerDispatch.forceActivateUser(usernameToActivate, moderatorName);
|
|
}
|
|
|
|
static getAdminNotes(userName: string, notes: string): void {
|
|
ServerDispatch.getAdminNotes(userName, notes);
|
|
}
|
|
|
|
static updateAdminNotes(userName: string, notes: string): void {
|
|
ServerDispatch.updateAdminNotes(userName, notes);
|
|
}
|
|
}
|