mirror of
https://github.com/qdm12/ddns-updater.git
synced 2026-04-05 08:54:09 -04:00
The loggingRoundTripper was unconditionally reading entire HTTP request/response bodies via io.ReadAll() on every round trip, even at the default Info log level. The expensive work (body read, string conversion, concatenation) happened before Debug() was called, so the logger's internal level check couldn't prevent it. Now makeLogClient skips wrapping the transport entirely when debug logging is not enabled, eliminating all overhead in the common case. Fixes #1096 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
11 KiB
11 KiB