mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-18 23:55:02 +00:00
Deprecate GuildActions. Fix double case posting when muting a user for message spam. Update to new mute/case style when muting a user for "other" spam.
GuildActions turned out to be a fairly pointless abstraction in the end. It didn't really solve the problems it was meant to solve (that is, reduce code spaghetti by having all inter-plugin calls go through a single service, and allow easier ways to replace core plugins with alternatives that share the same interface) any better than simply using `this.getPlugin()` when needed, and introduced extra complexity and made static analysis messier.
This commit is contained in:
parent
b95da113b2
commit
9a206455dc
10 changed files with 319 additions and 376 deletions
|
@ -8,22 +8,6 @@ import moment = require("moment-timezone");
|
|||
|
||||
const CASE_SUMMARY_REASON_MAX_LENGTH = 300;
|
||||
|
||||
/**
|
||||
* Used as a config object for functions that create cases
|
||||
*/
|
||||
export interface ICaseDetails {
|
||||
userId?: string;
|
||||
modId?: string;
|
||||
ppId?: string;
|
||||
type?: CaseTypes;
|
||||
auditLogId?: string;
|
||||
reason?: string;
|
||||
automatic?: boolean;
|
||||
postInCaseLogOverride?: boolean;
|
||||
noteDetails?: string[];
|
||||
extraNotes?: string[];
|
||||
}
|
||||
|
||||
export class GuildCases extends BaseRepository {
|
||||
private cases: Repository<Case>;
|
||||
private caseNotes: Repository<CaseNote>;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue