mirror of
https://codeberg.org/spire/dispenser.git
synced 2026-06-03 10:04:07 +02:00
lifetime fixes
This commit is contained in:
parent
2aa5ad868d
commit
7fb633eab3
1 changed files with 2 additions and 1 deletions
|
|
@ -140,7 +140,8 @@ fn stop_job(cloud: Arc<dyn Cloud>, config: &Config, server_id: Arc<Mutex<Option<
|
|||
let server_id = server_id.clone();
|
||||
let cloud = cloud.clone();
|
||||
spawn(async move {
|
||||
if let Some(id) = server_id.lock().unwrap().take() {
|
||||
let id = server_id.lock().unwrap().take();
|
||||
if let Some(id) = id {
|
||||
println!("Stopping server {}", id);
|
||||
match cloud.kill(&id).await {
|
||||
Ok(_) => {}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue