(payload)
| 5536 | } |
| 5537 | |
| 5538 | function pickExitIp(payload) { |
| 5539 | // 探针 JSON 里优先取 ip,兼容部分接口用 ipAddress 命名。 |
| 5540 | const ip = payload?.ip ?? payload?.ipAddress; |
| 5541 | return typeof ip === 'string' && ip ? ip : null; |
| 5542 | } |
| 5543 | |
| 5544 | function checkJsonResponse(data, status = 200) { |
| 5545 | return new Response(JSON.stringify(data, null, 2), { |
no outgoing calls
no test coverage detected