mirror of
https://github.com/spacebarchat/server.git
synced 2026-07-02 00:31:50 +00:00
Use subpath imports for lambert-server, fix openapi.js
This commit is contained in:
+1
-1
@@ -19,7 +19,7 @@
|
||||
import path from "node:path";
|
||||
import { Request, Response, Router } from "express";
|
||||
import morgan from "morgan";
|
||||
import { Server, ServerOptions } from "lambert-server";
|
||||
import { Server, ServerOptions } from "lambert-server/Server";
|
||||
import { red } from "picocolors";
|
||||
import { Config, ConnectionConfig, ConnectionLoader, Email, JSONReplacer, WebAuthn, initDatabase, initEvent, registerRoutes, getDatabase, getRevInfoOrFail } from "@spacebar/util";
|
||||
import { Authentication, CORS, ImageProxy, BodyParser, ErrorHandler, initRateLimits, initTranslation } from "./middlewares";
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
import { checkToken, Rights, Session, User, UserTokenData } from "@spacebar/util";
|
||||
import { NextFunction, Request, Response } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
export const NO_AUTHORIZATION_ROUTES = [
|
||||
// Authentication routes
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
import bodyParser, { OptionsJson } from "body-parser";
|
||||
import { NextFunction, Request, Response } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const errorMessages: { [key: string]: [string, number] } = {
|
||||
"entity.too.large": ["Request body too large", 413],
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
*/
|
||||
|
||||
import { NextFunction, Request, Response } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { ApiError, FieldError } from "@spacebar/util";
|
||||
const EntityNotFoundErrorRegex = /"(\w+)"/;
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Application, DiscordApiErrors, FieldErrors, User, createAppBotUser, generateToken, handleFile } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { verifyToken } from "node-2fa";
|
||||
import { BotModifySchema } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Application, DiscordApiErrors, FieldErrors, Guild, handleFile, User } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { verifyToken } from "node-2fa";
|
||||
import { ApplicationModifySchema } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Application, Guild, handleFile } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { ApplicationModifySchema } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { BackupCode, User, generateToken } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { verifyToken } from "node-2fa";
|
||||
import { TotpSchema } from "@spacebar/schemas";
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -20,7 +20,7 @@ import { route } from "@spacebar/api";
|
||||
import { generateToken, SecurityKey, User, verifyWebAuthnToken, WebAuthn } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { ExpectedAssertionResult } from "fido2-lib";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { WebAuthnTotpSchema } from "@spacebar/schemas";
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ import { route, verifyCaptcha } from "@spacebar/api";
|
||||
import { Config, FieldErrors, Invite, User, ValidRegistrationToken, generateToken, IpDataClient, AbuseIpDbClient, TimeSpan, Stopwatch } from "@spacebar/util";
|
||||
import bcrypt from "bcrypt";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { MoreThan } from "typeorm";
|
||||
import { RegisterSchema } from "@spacebar/schemas";
|
||||
import { BcryptWorkerPool } from "../../../util/util/workers/bcrypt/BcryptWorkerPool";
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Email, User } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
router.post(
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { randomString, route } from "@spacebar/api";
|
||||
import { Channel, Guild, Invite, InviteCreateEvent, PublicInviteRelation, User, emitEvent } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { InviteCreateSchema, isTextChannel } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -32,7 +32,7 @@ import {
|
||||
NewUrlUserSignatureData,
|
||||
} from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import multer from "multer";
|
||||
import { handleMessage, postHandleMessage, route } from "@spacebar/api";
|
||||
import { MessageCreateAttachment, MessageCreateCloudAttachment, MessageCreateSchema, MessageEditSchema, ChannelType } from "@spacebar/schemas";
|
||||
|
||||
@@ -33,7 +33,7 @@ import {
|
||||
ReactionType,
|
||||
} from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { In } from "typeorm";
|
||||
import { PartialEmoji, PublicMemberProjection, PublicUserProjection } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Channel, Config, emitEvent, getPermission, getRights, Message, MessageDeleteBulkEvent } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -44,7 +44,7 @@ import {
|
||||
ThreadCreateEvent,
|
||||
} from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import multer from "multer";
|
||||
import { FindManyOptions, FindOperator, LessThan, MoreThan, MoreThanOrEqual } from "typeorm";
|
||||
import { URL } from "node:url";
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Channel, FieldErrors, Message, getPermission } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { FindManyOptions, Like } from "typeorm";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
import { Channel, ChannelUpdateEvent, emitEvent, Member, Role } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
import { route } from "@spacebar/api";
|
||||
import { ChannelPermissionOverwriteSchema, ChannelPermissionOverwrite, ChannelPermissionOverwriteType } from "@spacebar/schemas";
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Channel, Message, MessageDeleteBulkEvent, emitEvent, getPermission, getRights } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { Between, FindManyOptions, FindOperator, Not } from "typeorm";
|
||||
import { isTextChannel, PurgeSchema } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ import { route } from "@spacebar/api";
|
||||
import { Channel, ChannelUpdateEvent, emitEvent, Tag } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { TagCreateSchema } from "@spacebar/schemas";
|
||||
import { HTTPError } from "#util/util/lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -37,7 +37,7 @@ import { ChannelType, MessageType, ThreadCreationSchema, MessageCreateAttachment
|
||||
|
||||
import { Request, Response, Router } from "express";
|
||||
import { messageUpload } from "./messages";
|
||||
import { HTTPError } from "#util/util/lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { FindManyOptions, FindOptionsOrder, In, Like, ArrayContains, ArrayOverlap } from "typeorm";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -20,7 +20,7 @@ import { route } from "@spacebar/api";
|
||||
import { Channel, Config, DiscordApiErrors, User, Webhook, handleFile, trimSpecial, ValidateName, Application } from "@spacebar/util";
|
||||
import crypto from "node:crypto";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { isTextChannel, WebhookCreateSchema, WebhookType } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { User, AutomodRule } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { AutomodRuleSchema } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Ban, DiscordApiErrors, GuildBanAddEvent, GuildBanRemoveEvent, Member, User, emitEvent } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { BanCreateSchema, BanRegistrySchema, GuildBanResponse, GuildBansResponse, PublicUser } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Ban, Config, DiscordApiErrors, GuildBanAddEvent, Member, User, emitEvent } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Guild, GuildDeleteEvent, emitEvent } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -32,7 +32,7 @@ import {
|
||||
Config,
|
||||
} from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { GuildCreateResponse, GuildUpdateSchema } from "@spacebar/schemas";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Member } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { MoreThan } from "typeorm";
|
||||
import { PublicMemberProjection } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Channel, FieldErrors, Member, Message, Snowflake, getPermission } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { Between, FindManyOptions, FindOptionsWhere, In, LessThan, Like, MoreThan } from "typeorm";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { emitEvent, GuildRoleDeleteEvent, GuildRoleUpdateEvent, handleFile, Member, Role } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { RoleModifySchema } from "@spacebar/schemas";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { GuildStickersUpdateEvent, Member, Snowflake, Sticker, emitEvent, uploadFile, Config, DiscordApiErrors } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import multer from "multer";
|
||||
import { ModifyGuildStickerSchema, StickerFormatType, StickerType } from "@spacebar/schemas";
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { generateCode, route } from "@spacebar/api";
|
||||
import { Guild, Template } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Channel, Guild, Invite } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { ChannelType, VanityUrlSchema } from "@spacebar/schemas";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -22,7 +22,7 @@ import { route } from "@spacebar/api";
|
||||
import { DiscordApiErrors, Guild } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import fs from "node:fs";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import path from "node:path";
|
||||
import { storage } from "@spacebar/cdn";
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ import { route } from "@spacebar/api";
|
||||
import { FieldErrors } from "@spacebar/util";
|
||||
import emailProviders from "email-providers/all.json";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { EmailDomainLookupResponse, EmailDomainLookupSchema, EmailDomainLookupVerifyCodeSchema } from "@spacebar/schemas";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Config, DiscordApiErrors, Guild, Member, Tag, Template } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { ChannelType, GuildTemplateCreateSchema } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -20,7 +20,7 @@ import { BaseMessageComponents, InteractionCallbackSchema, InteractionCallbacksS
|
||||
import { handleComps, route, sendMessage } from "@spacebar/api";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { Config, emitEvent, InteractionSuccessEvent, Message, MessageUpdateEvent, pendingInteractions, User, InteractionFailureEvent } from "@spacebar/util";
|
||||
import { HTTPError } from "#util/util/lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Ban, Config, DiscordApiErrors, emitEvent, getPermission, Guild, Invite, InviteDeleteEvent, PublicInviteRelation } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { UserFlags } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import fs from "node:fs";
|
||||
import path from "node:path";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { route } from "@spacebar/api";
|
||||
import { ReportMenuType, ReportMenuTypeNames, CreateReportSchema } from "@spacebar/schemas";
|
||||
import { FieldErrors } from "@spacebar/util";
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { Request, Response, Router } from "express";
|
||||
import { route } from "@spacebar/api";
|
||||
import { Team, TeamMember, User } from "@spacebar/util";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { TeamCreateSchema, TeamMemberRole, TeamMemberState } from "@spacebar/schemas";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
@@ -20,7 +20,7 @@ import { route } from "@spacebar/api";
|
||||
import { Guild, Member, User, UserSettingsProtos } from "@spacebar/util";
|
||||
import bcrypt from "bcrypt";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Config, Guild, Member } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
|
||||
const router: Router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { BackupCode, User, generateToken } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { verifyToken } from "node-2fa";
|
||||
import { TotpDisableSchema } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ import { route } from "@spacebar/api";
|
||||
import { User, generateMfaBackupCodes, generateToken } from "@spacebar/util";
|
||||
import bcrypt from "bcrypt";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { verifyToken } from "node-2fa";
|
||||
import { TotpEnableSchema } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -21,7 +21,7 @@ import { DiscordApiErrors, FieldErrors, generateWebAuthnTicket, SecurityKey, Use
|
||||
import bcrypt from "bcrypt";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { ExpectedAttestationResult } from "fido2-lib";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { CreateWebAuthnCredentialSchema, GenerateWebAuthnCredentialsSchema, WebAuthnPostSchema } from "@spacebar/schemas";
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
|
||||
@@ -19,7 +19,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Config, DiscordApiErrors, Relationship, RelationshipAddEvent, RelationshipRemoveEvent, RelationshipUpdateEvent, User, emitEvent } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { PublicUserProjection, RelationshipType, RelationshipPatchSchema } from "@spacebar/schemas";
|
||||
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
import { getProxyUrl, route } from "@spacebar/api";
|
||||
import { NextFunction, Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { executeWebhook } from "../../../../util/handlers/Webhook";
|
||||
import { EmbedType, WebhookExecuteSchema } from "@spacebar/schemas";
|
||||
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { route } from "@spacebar/api";
|
||||
import { Config, DiscordApiErrors, emitEvent, handleFile, ValidateName, Webhook, WebhooksUpdateEvent } from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import multer from "multer";
|
||||
import { executeWebhook } from "../../../../util/handlers/Webhook";
|
||||
import { WebhookUpdateSchema } from "@spacebar/schemas";
|
||||
|
||||
@@ -13,7 +13,7 @@ import {
|
||||
MessageDeleteBulkEvent,
|
||||
} from "@spacebar/util";
|
||||
import { Request, Response, Router } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { WebhookUpdateSchema } from "@spacebar/schemas";
|
||||
import { In } from "typeorm";
|
||||
const router = Router({ mergeParams: true });
|
||||
|
||||
@@ -53,7 +53,7 @@ import {
|
||||
USER_MENTION,
|
||||
Webhook,
|
||||
} from "@spacebar/util";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { Equal, In, Or } from "typeorm";
|
||||
import {
|
||||
ActionRowComponent,
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import { handleMessage, postHandleMessage } from "@spacebar/api";
|
||||
import { Attachment, Channel, Config, DiscordApiErrors, emitEvent, FieldErrors, Message, MessageCreateEvent, Snowflake, uploadFile, ValidateName, Webhook } from "@spacebar/util";
|
||||
import { Request, Response } from "express";
|
||||
import { HTTPError } from "lambert-server";
|
||||
import { HTTPError } from "lambert-server/HTTPError";
|
||||
import { MoreThan } from "typeorm";
|
||||
import { WebhookExecuteSchema } from "@spacebar/schemas";
|
||||
|
||||
|
||||
Reference in New Issue
Block a user