3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-10 12:25:02 +00:00

chore: fix lint errors; tweak lint rules

This commit is contained in:
Dragory 2023-05-08 22:58:51 +03:00
parent 9b3d6f5d68
commit 5f194bf1ef
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1
115 changed files with 176 additions and 264 deletions

View file

@ -20,7 +20,7 @@ export async function createCaseAction(
action: TCreateCaseAction,
values: TemplateSafeValueContainer,
event: TCustomEvent,
eventData: any,
eventData: any, // eslint-disable-line @typescript-eslint/no-unused-vars
) {
const modId = await renderTemplate(action.mod, values, false);
const targetId = await renderTemplate(action.target, values, false);

View file

@ -18,7 +18,7 @@ export async function makeRoleMentionableAction(
action: TMakeRoleMentionableAction,
values: TemplateSafeValueContainer,
event: TCustomEvent,
eventData: any,
eventData: any, // eslint-disable-line @typescript-eslint/no-unused-vars
) {
const role = pluginData.guild.roles.cache.get(action.role as Snowflake);
if (!role) {

View file

@ -16,7 +16,7 @@ export async function makeRoleUnmentionableAction(
action: TMakeRoleUnmentionableAction,
values: TemplateSafeValueContainer,
event: TCustomEvent,
eventData: any,
eventData: any, // eslint-disable-line @typescript-eslint/no-unused-vars
) {
const role = pluginData.guild.roles.cache.get(action.role as Snowflake);
if (!role) {

View file

@ -22,9 +22,9 @@ export type TSetChannelPermissionOverridesAction = t.TypeOf<typeof SetChannelPer
export async function setChannelPermissionOverridesAction(
pluginData: GuildPluginData<CustomEventsPluginType>,
action: TSetChannelPermissionOverridesAction,
values: TemplateSafeValueContainer,
event: TCustomEvent,
eventData: any,
values: TemplateSafeValueContainer, // eslint-disable-line @typescript-eslint/no-unused-vars
event: TCustomEvent, // eslint-disable-line @typescript-eslint/no-unused-vars
eventData: any, // eslint-disable-line @typescript-eslint/no-unused-vars
) {
const channel = pluginData.guild.channels.cache.get(action.channel as Snowflake);
if (!channel || channel.isThread() || !("guild" in channel)) {

View file

@ -15,10 +15,8 @@ const CommandTrigger = t.type({
params: t.string,
can_use: t.boolean,
});
type TCommandTrigger = t.TypeOf<typeof CommandTrigger>;
const AnyTrigger = CommandTrigger; // TODO: Make into a union once we have more triggers
type TAnyTrigger = t.TypeOf<typeof AnyTrigger>;
const AnyAction = t.union([
AddRoleAction,
@ -29,7 +27,6 @@ const AnyAction = t.union([
MakeRoleUnmentionableAction,
SetChannelPermissionOverridesAction,
]);
type TAnyAction = t.TypeOf<typeof AnyAction>;
export const CustomEvent = t.type({
name: t.string,