Fix/hostname field reset port and method #976

Closed
opened 2026-04-05 18:04:21 +02:00 by MrUnknownDE · 0 comments
Owner

Originally created by @Pallavikumarimdb on 9/1/2025

Community Contribution License Agreement

By creating this pull request, I grant the project maintainers an unlimited,
perpetual license to use, modify, and redistribute these contributions under any terms they
choose, including both the AGPLv3 and the Fossorial Commercial license terms. I
represent that I have the right to grant this license for all contributed content.

Description

Modified the handlers to only trigger URL parsing when the input actually looks like a URL.

Conditional updates:

  • Method: Only update if protocol was explicitly provided OR no method currently set
  • Port: Only update if port was explicitly provided OR no port currently set
  • IP: Always update (this is the primary field)

Preserve existing values: Plain IP/hostname entries don't trigger parsing at all.
Update the parseHostTarget to support h2c.

Fixes: #1393

How to test?

*Originally created by @Pallavikumarimdb on 9/1/2025* ## Community Contribution License Agreement By creating this pull request, I grant the project maintainers an unlimited, perpetual license to use, modify, and redistribute these contributions under any terms they choose, including both the AGPLv3 and the Fossorial Commercial license terms. I represent that I have the right to grant this license for all contributed content. ## Description Modified the handlers to only trigger URL parsing when the input actually looks like a URL. **Conditional updates:** - Method: Only update if protocol was explicitly provided OR no method currently set - Port: Only update if port was explicitly provided OR no port currently set - IP: Always update (this is the primary field) **Preserve existing values: Plain IP/hostname entries don't trigger parsing at all. Update the parseHostTarget to support h2c.** Fixes: #1393 ## How to test?
Sign in to join this conversation.
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github/pangolin#976