perf: use of or followed by a function call

This commit is contained in:
CosminPerRam 2023-12-11 03:58:40 +02:00
parent 0aa498b30b
commit a4bc430868
2 changed files with 5 additions and 5 deletions

View file

@ -85,7 +85,7 @@ pub fn query_with_timeout_and_extra_settings(
&socket_addr,
*engine,
extra_settings
.or(Option::from(game.request_settings.clone()))
.or_else(|| Option::from(game.request_settings.clone()))
.map(ExtraRequestSettings::into),
timeout_settings,
)