Skip to content

Commit

Permalink
feat: add docs
Browse files Browse the repository at this point in the history
Took 1 minute
  • Loading branch information
net-tech committed Oct 17, 2023
1 parent 1d55b85 commit 94b4aa9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -57,11 +57,13 @@ fn main() -> Result<()> {
};

for (idx, join_date) in matches.iter().enumerate() {
// Add the date to add a valid DateTime.
let mut date: DateTime<Utc> = DateTime::parse_from_str(
&format!("{}T{}", log_date, join_date),
"%Y/%m/%dT%H:%M:%S%.3f%z",
)
.with_context(|| format!("Could not parse date `{}T{}`", log_date, join_date))?
// Convert to UTC.
.try_into()
.with_context(|| format!("Could not parse date `{}T{}`", log_date, join_date))?;

Expand Down

0 comments on commit 94b4aa9

Please sign in to comment.