mirror of
https://github.com/tribufu/rust-gamedig
synced 2026-05-06 15:27:28 +00:00
chore: replace the closure with the method itself
This commit is contained in:
parent
e0cc2a2420
commit
1dc3c6dade
1 changed files with 1 additions and 1 deletions
|
|
@ -18,7 +18,7 @@ pub fn default_master_address() -> SocketAddr {
|
|||
fn construct_payload(region: Region, filters: &Option<SearchFilters>, last_ip: &str, last_port: u16) -> Vec<u8> {
|
||||
let filters_bytes: Vec<u8> = filters
|
||||
.as_ref()
|
||||
.map_or_else(|| vec![0x00], |f| f.to_bytes());
|
||||
.map_or_else(|| vec![0x00], SearchFilters::to_bytes);
|
||||
|
||||
let region_byte = &[region as u8];
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue