mirror of
https://github.com/Wei-Shaw/claude-relay-service.git
synced 2026-01-22 16:43:35 +00:00
fix: 修复 ESLint curly 规则问题
- 在 if 语句后添加必需的大括号 - 修复 unifiedClaudeScheduler.js (1处) - 修复 unstableUpstreamHelper.js (2处)
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
const logger = require('./logger')
|
||||
|
||||
function parseList(envValue) {
|
||||
if (!envValue) return []
|
||||
if (!envValue) {
|
||||
return []
|
||||
}
|
||||
return envValue
|
||||
.split(',')
|
||||
.map((s) => s.trim().toLowerCase())
|
||||
@@ -13,7 +15,9 @@ const unstableKeywords = parseList(process.env.UNSTABLE_ERROR_KEYWORDS)
|
||||
const unstableStatusCodes = new Set([408, 499, 502, 503, 504, 522])
|
||||
|
||||
function normalizeErrorPayload(payload) {
|
||||
if (!payload) return {}
|
||||
if (!payload) {
|
||||
return {}
|
||||
}
|
||||
|
||||
if (typeof payload === 'string') {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user