first commit
This commit is contained in:
10
frontend/app/api/admin/heroes/[id]/route.ts
Normal file
10
frontend/app/api/admin/heroes/[id]/route.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
import { NextRequest } from "next/server"
|
||||
import { handleImageProxyRequest } from "@/lib/api-proxy"
|
||||
|
||||
export async function PUT(
|
||||
req: NextRequest,
|
||||
context: { params: Promise<{ id: string }> }
|
||||
) {
|
||||
const { id } = await context.params
|
||||
return handleImageProxyRequest(req, `/admin/heroes/${id}`)
|
||||
}
|
||||
6
frontend/app/api/admin/heroes/route.ts
Normal file
6
frontend/app/api/admin/heroes/route.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
import { NextRequest } from "next/server"
|
||||
import { handleImageProxyRequest } from "@/lib/api-proxy"
|
||||
|
||||
export async function POST(req: NextRequest) {
|
||||
return handleImageProxyRequest(req, "/admin/heroes")
|
||||
}
|
||||
Reference in New Issue
Block a user