fix: 优化验证器代码格式,提升可读性

This commit is contained in:
sususu
2025-10-17 15:30:05 +08:00
parent b0917b75a4
commit 77bca73094
3 changed files with 6 additions and 3 deletions

View File

@@ -131,7 +131,7 @@ class ClaudeCodeValidator {
const userAgent = req.headers['user-agent'] || ''
const path = req.path || ''
const claudeCodePattern = /^claude-cli\/\d+\.\d+\.\d+/i;
const claudeCodePattern = /^claude-cli\/\d+\.\d+\.\d+/i
if (!claudeCodePattern.test(userAgent)) {
// 不是 Claude Code 的请求,此验证器不处理