diff --git a/typhon/src/api.rs b/typhon/src/api.rs index 0bcda3bb..fcd93d6c 100644 --- a/typhon/src/api.rs +++ b/typhon/src/api.rs @@ -201,7 +201,10 @@ async fn drv_log(path: web::Json) -> HttpResponse { }); HttpResponse::Ok().streaming(stream) } - None => HttpResponse::Ok().body(web::Bytes::from(nix::log(path).await.unwrap())), + None => match nix::log(path).await { + Ok(log) => HttpResponse::Ok().body(web::Bytes::from(log)), + Err(_) => HttpResponse::NotFound().finish(), + }, } }