Skip to content

Commit

Permalink
Fix for production feature error handling for quote generation
Browse files Browse the repository at this point in the history
  • Loading branch information
ameba23 committed Dec 2, 2024
1 parent fddd9e4 commit a41302c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion crates/threshold-signature-server/src/attestation/api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,8 @@ pub async fn create_quote(
context,
);

Ok(configfs_tsm::create_quote(input_data.0)?)
Ok(configfs_tsm::create_quote(input_data.0)
.map_err(|e| AttestationErr::QuoteGeneration(format!("{:?}", e)))?)
}

/// Querystring for the GET `/attest` endpoint
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ pub enum AttestationErr {
Codec(#[from] parity_scale_codec::Error),
#[cfg(feature = "production")]
#[error("Quote generation: {0}")]
QuoteGeneration(#[from] std::io::Error),
QuoteGeneration(String),
#[error("Vec<u8> Conversion Error: {0}")]
Conversion(&'static str),
#[error("Data is repeated")]
Expand Down

0 comments on commit a41302c

Please sign in to comment.