rustls / rustls-ffi

Use Rustls from any language
Other
123 stars 31 forks source link

server: fix clippy::manual_unwrap_or_default finding #399

Closed cpu closed 3 months ago

cpu commented 3 months ago
warning: match can be simplified with `.unwrap_or_default()`
   --> src/server.rs:486:13
    |
486 | /             match client_hello.server_name() {
487 | |                 Some(c) => c,
488 | |                 None => "",
489 | |             }
    | |_____________^ help: replace it with: `client_hello.server_name().unwrap_or_default()`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#manual_unwrap_or_default
    = note: `#[warn(clippy::manual_unwrap_or_default)]` on by default