|
@@ -1,5 +1,4 @@
|
|
|
import { writeFile } from "fs/promises";
|
|
|
-import { chmod } from "fs/promises";
|
|
|
import { NextResponse } from "next/server";
|
|
|
import path from "path";
|
|
|
import { setCORSHeaders } from "../../lib/apiUtils";
|
|
@@ -26,9 +25,6 @@ export async function POST(request) {
|
|
|
|
|
|
await writeFile(filepath, buffer);
|
|
|
|
|
|
- // 设置文件权限为 0755 (rwxr-xr-x)
|
|
|
- await chmod(filepath, 0o755);
|
|
|
-
|
|
|
const response = NextResponse.json({
|
|
|
success: true,
|
|
|
filename,
|