mirror of
https://codeberg.org/spire/dispenser.git
synced 2026-06-03 18:14:06 +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 server_id = server_id.clone();
|
||||||
let cloud = cloud.clone();
|
let cloud = cloud.clone();
|
||||||
spawn(async move {
|
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);
|
println!("Stopping server {}", id);
|
||||||
match cloud.kill(&id).await {
|
match cloud.kill(&id).await {
|
||||||
Ok(_) => {}
|
Ok(_) => {}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue