(method, requestPath, elapsedMs, buffer)
| 2186 | } |
| 2187 | |
| 2188 | function logHttpResult(method, requestPath, elapsedMs, buffer) { |
| 2189 | if (!traceHttp) { |
| 2190 | return; |
| 2191 | } |
| 2192 | const text = buffer.toString("utf8"); |
| 2193 | const preview = text.length > 0 && text.length <= 1_000 ? `\n${text}` : ""; |
| 2194 | console.log(`[ok ${elapsedMs}ms] ${method} ${requestPath}${preview}`); |
| 2195 | } |
| 2196 | |
| 2197 | function shellQuote(parts) { |
| 2198 | return parts |
no test coverage detected