Skip to content

Commit

Permalink
fix trailing slash not being removed from domain
Browse files Browse the repository at this point in the history
  • Loading branch information
BlockListed committed Feb 7, 2023
1 parent a72d0b5 commit 679bc7a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/auth.rs
Original file line number Diff line number Diff line change
Expand Up @@ -283,7 +283,8 @@ impl<'r> FromRequest<'r> for Host {

// Get host
let host = if CONFIG.domain_set() {
CONFIG.domain()
// Remove trailing slash if it exists since we're getting a host
CONFIG.domain().trim_end_matches('/').to_string()
} else if let Some(referer) = headers.get_one("Referer") {
referer.to_string()
} else {
Expand Down

0 comments on commit 679bc7a

Please sign in to comment.