mirror of
https://github.com/NeteaseCloudMusicApiEnhanced/api-enhanced.git
synced 2026-10-20 22:51:23 +08:00
style(code): 格式化代码
- 将长参数列表拆分为多行以提高可读性 - 标准化函数调用中的逗号使用 - 统一对象和数组的换行格式 - 更新 ESLint 配置中的 ECMA 版本至 2020,以支持 ES2020 语法(包括 Optional Chaining) - 优化代码缩进和对齐方式 - 确保所有文件中的代码风格一致性
This commit is contained in:
@@ -182,17 +182,21 @@ async function consturctServer(moduleDefs) {
|
||||
const MAX_UPLOAD_SIZE_BYTES = MAX_UPLOAD_SIZE_MB * 1024 * 1024
|
||||
|
||||
app.use(express.json({ limit: `${MAX_UPLOAD_SIZE_MB}mb` }))
|
||||
app.use(express.urlencoded({ extended: false, limit: `${MAX_UPLOAD_SIZE_MB}mb` }))
|
||||
app.use(
|
||||
express.urlencoded({ extended: false, limit: `${MAX_UPLOAD_SIZE_MB}mb` }),
|
||||
)
|
||||
|
||||
app.use(fileUpload({
|
||||
limits: {
|
||||
fileSize: MAX_UPLOAD_SIZE_BYTES
|
||||
},
|
||||
useTempFiles: true,
|
||||
tempFileDir: require('os').tmpdir(),
|
||||
abortOnLimit: true,
|
||||
parseNested: true
|
||||
}))
|
||||
app.use(
|
||||
fileUpload({
|
||||
limits: {
|
||||
fileSize: MAX_UPLOAD_SIZE_BYTES,
|
||||
},
|
||||
useTempFiles: true,
|
||||
tempFileDir: require('os').tmpdir(),
|
||||
abortOnLimit: true,
|
||||
parseNested: true,
|
||||
}),
|
||||
)
|
||||
|
||||
/**
|
||||
* Cache
|
||||
|
||||
Reference in New Issue
Block a user