Simplify usage of federation_sender_config Option

pull/4864/head
Richard Schwab 2024-06-25 00:40:16 +02:00
parent 3971c391d4
commit 83e65959de
No known key found for this signature in database
1 changed files with 2 additions and 2 deletions

View File

@ -226,13 +226,13 @@ pub async fn start_lemmy_server(args: CmdArgs) -> LemmyResult<()> {
} else {
None
};
let federate = (!args.disable_activity_sending).then(|| {
let federate = federation_sender_config.map(|cfg| {
SendManager::run(
Opts {
process_index: args.federate_process_index,
process_count: args.federate_process_count,
},
federation_sender_config.expect("same condition as the execution of this code"),
cfg,
)
});
let mut interrupt = tokio::signal::unix::signal(SignalKind::interrupt())?;