Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
Signed-off-by: Jun Kimura <jun.kimura@datachain.jp>
  • Loading branch information
bluele committed Dec 16, 2024
1 parent e73a3b7 commit 5cbcff4
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions modules/keymanager/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -252,15 +252,17 @@ impl EnclaveKeyManager {
anyhow!("report: {:?}", e).into(),
)
})?,
ias_report: Some(
IASSignedReport::from_json(&row.get::<_, String>(4)?).map_err(|e| {
ias_report: match row.get::<_, Option<String>>(4) {
Ok(None) => None,
Ok(Some(avr)) => Some(IASSignedReport::from_json(&avr).map_err(|e| {
rusqlite::Error::FromSqlConversionFailure(
4,
Type::Text,
anyhow!("ias_report: {:?}", e).into(),
)
})?,
),
})?),
Err(e) => return Err(e),
},
dcap_quote: match row.get::<_, Option<String>>(5) {
Ok(None) => None,
Ok(Some(dq)) => Some(DCAPQuote::from_json(&dq).map_err(|e| {
Expand Down

0 comments on commit 5cbcff4

Please sign in to comment.