mirror of
https://github.com/actix/actix-extras.git
synced 2025-06-26 02:19:22 +02:00
clippy warnings
This commit is contained in:
@ -1007,22 +1007,22 @@ impl Protocol {
|
||||
}
|
||||
}
|
||||
|
||||
fn is_http(&self) -> bool {
|
||||
match *self {
|
||||
fn is_http(self) -> bool {
|
||||
match self {
|
||||
Protocol::Https | Protocol::Http => true,
|
||||
_ => false,
|
||||
}
|
||||
}
|
||||
|
||||
fn is_secure(&self) -> bool {
|
||||
match *self {
|
||||
fn is_secure(self) -> bool {
|
||||
match self {
|
||||
Protocol::Https | Protocol::Wss => true,
|
||||
_ => false,
|
||||
}
|
||||
}
|
||||
|
||||
fn port(&self) -> u16 {
|
||||
match *self {
|
||||
fn port(self) -> u16 {
|
||||
match self {
|
||||
Protocol::Http | Protocol::Ws => 80,
|
||||
Protocol::Https | Protocol::Wss => 443,
|
||||
}
|
||||
|
Reference in New Issue
Block a user