(req: Request)
| 1 | import { cloudinary } from '@/lib/cloudinary'; |
| 2 | |
| 3 | export async function POST(req: Request) { |
| 4 | const publicId = await req.json(); |
| 5 | |
| 6 | try { |
| 7 | await cloudinary.v2.uploader.destroy(publicId); |
| 8 | return new Response(null, { status: 200 }); |
| 9 | } catch (err) { |
| 10 | console.error('Cloudinary delete failed', err); |
| 11 | return new Response("Failed to delete", { status: 500 }); |
| 12 | } |
| 13 | } |
nothing calls this directly
no outgoing calls
no test coverage detected
searching dependent graphs…