mirror of
https://github.com/kmc7468/arkvault.git
synced 2026-11-04 08:10:28 +09:00
리다이렉트 경로 처리, 파일 정보 변환, 상태 표시 UI 등 중복된 코드를 통합하고 모듈 간 순환 의존성 및 계층 위반 해소
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
9119c21881
commit
5b8621e524
96 files changed
+452
-548
No files matched your search
+8
-5
@@ -1,9 +1,13 @@
|
||||
import { sequence, type ServerInit } from "@sveltejs/kit/hooks";
|
||||
import schedule from "node-schedule";
|
||||
import { ClientRepo, SessionRepo } from "#lib/server/db/index.ts";
|
||||
import { migrateDB } from "#lib/server/db/kysely.ts";
|
||||
import { authenticate, setAgentInfo } from "#lib/server/middlewares/index.ts";
|
||||
import { FileDeletionService, UploadService } from "#lib/server/services/index.ts";
|
||||
import {
|
||||
AuthService,
|
||||
ClientService,
|
||||
FileDeletionService,
|
||||
UploadService,
|
||||
} from "#lib/server/services/index.ts";
|
||||
|
||||
export const init: ServerInit = async () => {
|
||||
await migrateDB();
|
||||
@@ -11,9 +15,8 @@ export const init: ServerInit = async () => {
|
||||
schedule.scheduleJob("0 * * * *", async () => {
|
||||
// Failures are logged and retried at the next run, so they don't crash the server
|
||||
const results = await Promise.allSettled([
|
||||
ClientRepo.cleanupExpiredUserClientChallenges(),
|
||||
SessionRepo.cleanupExpiredSessions(),
|
||||
SessionRepo.cleanupExpiredSessionUpgradeChallenges(),
|
||||
AuthService.cleanupExpiredSessions(),
|
||||
ClientService.cleanupExpiredChallenges(),
|
||||
UploadService.cleanupExpiredUploadSessions(),
|
||||
]);
|
||||
results.forEach((result) => {
|
||||
|
||||
Reference in new issue
Block a user