Skip to content

Commit

Permalink
update timetamps that are now optional as well
Browse files Browse the repository at this point in the history
  • Loading branch information
mellowagain committed Feb 21, 2024
1 parent f33a399 commit bdef6a3
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions src/integrations.rs
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,14 @@ impl From<IntegrationSummary> for IntegrationRow {
Self {
id: integration.id.to_string(),
status: integration.status.to_string(),
created_at: integration.created_at.format(&Rfc3339).unwrap_or_default(),
updated_at: integration.updated_at.format(&Rfc3339).unwrap_or_default(),
created_at: integration.created_at.map_or_else(
|| "n/a".to_string(),
|time| time.format(&Rfc3339).unwrap_or_default(),
),
updated_at: integration.updated_at.map_or_else(
|| "n/a".to_string(),
|time| time.format(&Rfc3339).unwrap_or_default(),
),
}
}
}

0 comments on commit bdef6a3

Please sign in to comment.