Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement the OptionalFromRequestParts trait for the Host extractor #3177

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

dnlsndr
Copy link

@dnlsndr dnlsndr commented Jan 14, 2025

Fixes: #3170

Motivation

To allow for Option<Host> extractors we need to implement the OptionalFromRequestParts trait for it.

Solution

Implement OptionalFromRequestParts for the Host Extractor

@dnlsndr dnlsndr marked this pull request as ready for review January 14, 2025 19:44
axum-extra/src/extract/host.rs Outdated Show resolved Hide resolved
axum-extra/src/extract/host.rs Outdated Show resolved Hide resolved
Copy link
Collaborator

@Turbo87 Turbo87 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM thanks :)

@Turbo87 Turbo87 requested a review from jplatte January 15, 2025 08:54
@Turbo87 Turbo87 added C-enhancement Category: A PR with an enhancement A-axum-extra labels Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-axum-extra C-enhancement Category: A PR with an enhancement
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missing OptionalFromRequestParts implementation for the Host extractor from the axum-extra crate
3 participants