Add redirect option to strip headers on redirect by mcollina · Pull Request #5281 · nodejs/undici (original) (raw)

Conversation

@mcollina

This relates to...

N/A

Rationale

Allow callers using the redirect interceptor to remove selected custom request headers before a redirected request is dispatched, with support for both all redirects and cross-origin redirects only.

Changes

Features

Bug Fixes

Breaking Changes and Deprecations

N/A

Status

Tests

@mcollina

@mcollina

@codecov-commenter

Codecov Report

❌ Patch coverage is 89.74359% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 93.25%. Comparing base (13f6af6) to head (48d84f7).
⚠️ Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
lib/handler/redirect-handler.js 88.88% 4 Missing ⚠️

Additional details and impacted files

@@ Coverage Diff @@ ## main #5281 +/- ##

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:

metcoder95

@mcollina

@mcollina

metcoder95

@mcollina mcollina deleted the add-redirect-strip-headers-option branch

May 18, 2026 16:10

This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters

[ Show hidden characters]({{ revealButtonHref }})