mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-11-27 14:51:18 +00:00
Remove condition that's not needed anymore
This commit is contained in:
parent
db856efcdb
commit
d82bfccc5b
1 changed files with 9 additions and 11 deletions
|
@ -265,7 +265,6 @@ pub async fn start_lemmy_server(args: CmdArgs) -> LemmyResult<()> {
|
||||||
let mut interrupt = tokio::signal::unix::signal(SignalKind::interrupt())?;
|
let mut interrupt = tokio::signal::unix::signal(SignalKind::interrupt())?;
|
||||||
let mut terminate = tokio::signal::unix::signal(SignalKind::terminate())?;
|
let mut terminate = tokio::signal::unix::signal(SignalKind::terminate())?;
|
||||||
|
|
||||||
if server.is_some() || federate.is_some() || scheduled_tasks.is_some() {
|
|
||||||
tokio::select! {
|
tokio::select! {
|
||||||
_ = tokio::signal::ctrl_c() => {
|
_ = tokio::signal::ctrl_c() => {
|
||||||
tracing::warn!("Received ctrl-c, shutting down gracefully...");
|
tracing::warn!("Received ctrl-c, shutting down gracefully...");
|
||||||
|
@ -277,7 +276,6 @@ pub async fn start_lemmy_server(args: CmdArgs) -> LemmyResult<()> {
|
||||||
tracing::warn!("Received terminate, shutting down gracefully...");
|
tracing::warn!("Received terminate, shutting down gracefully...");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
if let Some(server) = server {
|
if let Some(server) = server {
|
||||||
server.stop(true).await;
|
server.stop(true).await;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue