delete file and remove token from hashmap
This commit is contained in:
parent
379406a331
commit
459754bd8c
@ -99,7 +99,9 @@ async fn process_request(request: Request, token_list: TokenList, build_sender:
|
||||
build_sender.send(args).await.ok();
|
||||
},
|
||||
Request::Delete(token) => {
|
||||
println!("delete file with token={}", token);
|
||||
fs::remove_file(format!("./out/ssm-{}", token)).await.ok();
|
||||
let mut token_list = token_list.lock().unwrap();
|
||||
token_list.remove(&token);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user