Skip to content

Commit

Permalink
fix: pod create when challenge not found
Browse files Browse the repository at this point in the history
  • Loading branch information
ElaBosak233 committed Nov 17, 2024
1 parent 28ed502 commit 883256a
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ fred = { version = "9.3", features = [
] }

# Containerization & Orchestration
kube = { version = "0.96", features = ["runtime", "derive", "rustls-tls", "ws"] }
kube = { version = "0.96", features = ["client", "config", "runtime", "derive", "rustls-tls", "ws"] }
k8s-openapi = { version = "0.23", features = ["latest"] }

# Miscellaneous
Expand Down
2 changes: 1 addition & 1 deletion src/web/router/api/pod/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ pub async fn create(
.one(&get_db())
.await?;

let challenge = challenge.unwrap();
let challenge = challenge.ok_or(WebError::BadRequest(String::from("challenge_not_found")))?;

let ctn_name = format!("cds-{}", Uuid::new_v4().simple().to_string());

Expand Down

0 comments on commit 883256a

Please sign in to comment.