loadstar/src/entities/request.rs

14 lines
241 B
Rust
Raw Normal View History

2024-08-20 06:05:01 +00:00
use tiny_http::Request;
pub trait Url {
fn get_url_without_parameters(&self) -> String;
}
impl Url for Request {
fn get_url_without_parameters(&self) -> String {
self.url().split("?").next().unwrap().to_string()
}
}