mirror of
https://github.com/Drop-OSS/drop.git
synced 2025-11-16 01:31:19 +10:00
fix: inital eslint errors
This commit is contained in:
@ -1,6 +1,6 @@
|
||||
import path from "path";
|
||||
import fs from "fs";
|
||||
import { CertificateBundle } from "./ca";
|
||||
import type { CertificateBundle } from "./ca";
|
||||
import prisma from "../db/database";
|
||||
|
||||
export type CertificateStore = {
|
||||
|
||||
@ -1,7 +1,8 @@
|
||||
import path from "path";
|
||||
import fs from "fs";
|
||||
import droplet from "@drop-oss/droplet";
|
||||
import { CertificateStore, fsCertificateStore } from "./ca-store";
|
||||
import type { CertificateStore} from "./ca-store";
|
||||
import { fsCertificateStore } from "./ca-store";
|
||||
|
||||
export type CertificateBundle = {
|
||||
priv: string;
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
import { EnumDictionary } from "../utils/types";
|
||||
import type { EnumDictionary } from "../utils/types";
|
||||
import https from "https";
|
||||
import { useCertificateAuthority } from "~/server/plugins/ca";
|
||||
import prisma from "../db/database";
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { Client, User } from "@prisma/client";
|
||||
import { EventHandlerRequest, H3Event } from "h3";
|
||||
import type { Client, User } from "@prisma/client";
|
||||
import type { EventHandlerRequest, H3Event } from "h3";
|
||||
import droplet from "@drop-oss/droplet";
|
||||
import prisma from "../db/database";
|
||||
import { useCertificateAuthority } from "~/server/plugins/ca";
|
||||
@ -26,7 +26,7 @@ export function defineClientEventHandler<T>(handler: EventHandlerFunction<T>) {
|
||||
let clientId: string;
|
||||
switch (method) {
|
||||
case "Debug":
|
||||
if (!process.dev) throw createError({ statusCode: 403 });
|
||||
if (!import.meta.dev) throw createError({ statusCode: 403 });
|
||||
const client = await prisma.client.findFirst({ select: { id: true } });
|
||||
if (!client)
|
||||
throw createError({
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
import { randomUUID } from "node:crypto";
|
||||
import { CertificateBundle } from "./ca";
|
||||
import prisma from "../db/database";
|
||||
import { Platform } from "@prisma/client";
|
||||
import type { Platform } from "@prisma/client";
|
||||
import { useCertificateAuthority } from "~/server/plugins/ca";
|
||||
|
||||
export interface ClientMetadata {
|
||||
|
||||
Reference in New Issue
Block a user