3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-07-07 19:17:19 +00:00

feat: update to djs 14.19.3, node 22, zod 4

This commit is contained in:
Dragory 2025-05-22 22:35:48 +00:00
parent 595e1a0556
commit 09eb8e92f2
No known key found for this signature in database
189 changed files with 1244 additions and 900 deletions

View file

@ -1,5 +1,5 @@
import { PermissionFlagsBits, Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { nonNullish, unique, zSnowflake } from "../../../utils.js";
import { canAssignRole } from "../../../utils/canAssignRole.js";
import { getMissingPermissions } from "../../../utils/getMissingPermissions.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { zBoundedCharacters } from "../../../utils.js";
import { CountersPlugin } from "../../Counters/CountersPlugin.js";
import { LogsPlugin } from "../../Logs/LogsPlugin.js";

View file

@ -1,5 +1,5 @@
import { Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { LogType } from "../../../data/LogType.js";
import {
createTypedTemplateSafeValueContainer,

View file

@ -1,5 +1,5 @@
import { AnyThreadChannel } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { noop } from "../../../utils.js";
import { automodAction } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import {
convertDelayStringToMS,
nonNullish,

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { nonNullish, unique, zBoundedCharacters } from "../../../utils.js";
import { LogsPlugin } from "../../Logs/LogsPlugin.js";
import { automodAction } from "../helpers.js";

View file

@ -1,6 +1,6 @@
import { PermissionsBitField, PermissionsString } from "discord.js";
import { U } from "ts-toolbelt";
import z from "zod";
import z from "zod/v4";
import { TemplateParseError, TemplateSafeValueContainer, renderTemplate } from "../../../templateFormatter.js";
import { isValidSnowflake, keys, noop, zBoundedCharacters } from "../../../utils.js";
import {

View file

@ -1,5 +1,5 @@
import { GuildTextBasedChannel, Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { LogType } from "../../../data/LogType.js";
import { noop } from "../../../utils.js";
import { automodAction } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { zBoundedCharacters } from "../../../utils.js";
import { automodAction } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { asyncMap, nonNullish, resolveMember, unique, zBoundedCharacters, zSnowflake } from "../../../utils.js";
import { CaseArgs } from "../../Cases/types.js";
import { ModActionsPlugin } from "../../ModActions/ModActionsPlugin.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { isTruthy, unique } from "../../../utils.js";
import { LogsPlugin } from "../../Logs/LogsPlugin.js";
import { automodAction } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { ERRORS, RecoverablePluginError } from "../../../RecoverablePluginError.js";
import {
convertDelayStringToMS,

View file

@ -1,5 +1,5 @@
import { GuildFeature } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { automodAction } from "../helpers.js";
export const PauseInvitesAction = automodAction({

View file

@ -1,5 +1,5 @@
import { PermissionFlagsBits, Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { nonNullish, unique, zSnowflake } from "../../../utils.js";
import { canAssignRole } from "../../../utils/canAssignRole.js";
import { getMissingPermissions } from "../../../utils/getMissingPermissions.js";

View file

@ -1,5 +1,5 @@
import { GuildTextBasedChannel, MessageCreateOptions, PermissionsBitField, Snowflake, User } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { TemplateParseError, TemplateSafeValueContainer, renderTemplate } from "../../../templateFormatter.js";
import {
convertDelayStringToMS,

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { MAX_COUNTER_VALUE, MIN_COUNTER_VALUE } from "../../../data/GuildCounters.js";
import { zBoundedCharacters } from "../../../utils.js";
import { CountersPlugin } from "../../Counters/CountersPlugin.js";

View file

@ -1,5 +1,5 @@
import { ChannelType, GuildTextBasedChannel, Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { convertDelayStringToMS, isDiscordAPIError, zDelayString, zSnowflake } from "../../../utils.js";
import { LogsPlugin } from "../../Logs/LogsPlugin.js";
import { automodAction } from "../helpers.js";

View file

@ -1,5 +1,5 @@
import { ChannelType, GuildTextThreadCreateOptions, ThreadAutoArchiveDuration, ThreadChannel } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { TemplateParseError, TemplateSafeValueContainer, renderTemplate } from "../../../templateFormatter.js";
import { MINUTES, convertDelayStringToMS, noop, zBoundedCharacters, zDelayString } from "../../../utils.js";
import { savedMessageToTemplateSafeSavedMessage, userToTemplateSafeUser } from "../../../utils/templateSafeObjects.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { asyncMap, nonNullish, resolveMember, unique, zBoundedCharacters, zSnowflake } from "../../../utils.js";
import { CaseArgs } from "../../Cases/types.js";
import { ModActionsPlugin } from "../../ModActions/ModActionsPlugin.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { MINUTES, SECONDS } from "../../utils.js";
export const RECENT_SPAM_EXPIRY_TIME = 10 * SECONDS;

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { SavedMessage } from "../../../data/entities/SavedMessage.js";
import { humanizeDurationShort } from "../../../humanizeDuration.js";
import { getBaseUrl } from "../../../pluginUtils.js";

View file

@ -1,5 +1,5 @@
import { GuildPluginData } from "knub";
import z, { ZodTypeAny } from "zod";
import z, { ZodTypeAny } from "zod/v4";
import { Awaitable } from "../../utils/typeUtils.js";
import { AutomodContext, AutomodPluginType } from "./types.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
interface AntiraidLevelTriggerResult {}

View file

@ -1,5 +1,5 @@
import { Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { verboseChannelMention } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line:no-empty-interface

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
interface ExampleMatchResultType {

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line:no-empty-interface

View file

@ -1,6 +1,6 @@
import { escapeInlineCode, Snowflake } from "discord.js";
import { extname } from "path";
import z from "zod";
import z from "zod/v4";
import { asSingleLine, messageSummary, verboseChannelMention } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { getInviteCodesInString, GuildInvite, isGuildInvite, resolveInvite, zSnowflake } from "../../../utils.js";
import { getTextMatchPartialSummary } from "../functions/getTextMatchPartialSummary.js";
import { MatchableTextType, matchMultipleTextTypesOnMessage } from "../functions/matchMultipleTextTypesOnMessage.js";

View file

@ -1,5 +1,5 @@
import { escapeInlineCode } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { allowTimeout } from "../../../RegExpRunner.js";
import { phishermanDomainIsSafe } from "../../../data/Phisherman.js";
import { getUrlsInString, zRegex } from "../../../utils.js";

View file

@ -1,5 +1,5 @@
import { escapeInlineCode } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { asSingleLine, messageSummary, verboseChannelMention } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { allowTimeout } from "../../../RegExpRunner.js";
import { zRegex } from "../../../utils.js";
import { mergeRegexes } from "../../../utils/mergeRegexes.js";

View file

@ -1,5 +1,5 @@
import escapeStringRegexp from "escape-string-regexp";
import z from "zod";
import z from "zod/v4";
import { normalizeText } from "../../../utils/normalizeText.js";
import { stripMarkdown } from "../../../utils/stripMarkdown.js";
import { getTextMatchPartialSummary } from "../functions/getTextMatchPartialSummary.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { convertDelayStringToMS, zDelayString } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { convertDelayStringToMS, zDelayString } from "../../../utils.js";
import { RecentActionType } from "../constants.js";
import { findRecentSpam } from "../functions/findRecentSpam.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
const configSchema = z.strictObject({});

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line:no-empty-interface

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line:no-empty-interface

View file

@ -1,5 +1,5 @@
import { Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { renderUsername, zSnowflake } from "../../../utils.js";
import { consumeIgnoredRoleChange } from "../functions/ignoredRoleChanges.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,5 +1,5 @@
import { Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { renderUsername, zSnowflake } from "../../../utils.js";
import { consumeIgnoredRoleChange } from "../functions/ignoredRoleChanges.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,5 +1,5 @@
import { User, escapeBold, type Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { renderUsername } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,5 +1,5 @@
import { User, escapeBold, type Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { renderUsername } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { convertDelayStringToMS, zDelayString } from "../../../utils.js";
import { RecentActionType } from "../constants.js";
import { findRecentSpam } from "../functions/findRecentSpam.js";

View file

@ -1,5 +1,5 @@
import { User, escapeBold, type Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { renderUsername } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,5 +1,5 @@
import { User, escapeBold, type Snowflake } from "discord.js";
import z from "zod";
import z from "zod/v4";
import { renderUsername } from "../../../utils.js";
import { automodTrigger } from "../helpers.js";

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line:no-empty-interface

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line:no-empty-interface

View file

@ -1,4 +1,4 @@
import z from "zod";
import z from "zod/v4";
import { automodTrigger } from "../helpers.js";
// tslint:disable-next-line:no-empty-interface

View file

@ -1,6 +1,6 @@
import { GuildMember, GuildTextBasedChannel, PartialGuildMember, ThreadChannel, User } from "discord.js";
import { BasePluginType, CooldownManager, pluginUtils } from "knub";
import z from "zod";
import z from "zod/v4";
import { Queue } from "../../Queue.js";
import { RegExpRunner } from "../../RegExpRunner.js";
import { GuildAntiraidLevels } from "../../data/GuildAntiraidLevels.js";