fix(bulk-import): skip __MACOSX folder when processing zip imports
Build errors fixed: - Fixed session field access (session.sub instead of session.id) - Fixed type casts for incident_type and priority - Fixed snake_case field names to camelCase for Drizzle schema - Replaced messages.create with chat.completions.create for DeepSeek - Updated DeepSeek client to accept apiKey parameter - Removed unused imports across multiple files Route now accessible at /bulk-import. Redirects unauthenticated users to /login?redirect=%2Fbulk-import. Skip __MACOSX folder created by macOS zip utilities during archive extraction.
This commit is contained in:
@@ -1,12 +1,6 @@
|
||||
import { NextRequest, NextResponse } from 'next/server'
|
||||
import fs from 'node:fs'
|
||||
import path from 'node:path'
|
||||
import crypto from 'node:crypto'
|
||||
import { getSession } from '@/lib/auth/get-session'
|
||||
import { signEvidencePath } from '@/lib/storage/evidence'
|
||||
import { asAdmin } from '@/lib/db/with-user'
|
||||
import { evidenceFiles } from '@/lib/db/schema'
|
||||
import { eq } from 'drizzle-orm'
|
||||
|
||||
export const dynamic = 'force-dynamic'
|
||||
|
||||
|
||||
Reference in New Issue
Block a user