From 22c4a3b37574b7dfab7dde0420dd40235acec350 Mon Sep 17 00:00:00 2001 From: Ruben Fiszel Date: Fri, 7 Oct 2022 16:11:38 +0200 Subject: [PATCH] fix(backend): go lock dependency with no requirements --- backend/src/worker.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/backend/src/worker.rs b/backend/src/worker.rs index a1c943f48d..0b367d7137 100644 --- a/backend/src/worker.rs +++ b/backend/src/worker.rs @@ -1452,8 +1452,9 @@ async fn install_go_dependencies( req_content.push_str(&format!("\n{GO_REQ_SPLITTER}\n")); - let mut file = File::open(format!("{job_dir}/go.sum")).await?; - file.read_to_string(&mut req_content).await?; + if let Ok(mut file) = File::open(format!("{job_dir}/go.sum")).await { + file.read_to_string(&mut req_content).await?; + } Ok(req_content) }