Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

setting generated_at attribute of exported snapshot header #94

Merged
merged 2 commits into from
Apr 23, 2024

Conversation

vbar
Copy link
Collaborator

@vbar vbar commented Apr 23, 2024

No description provided.

@vbar vbar requested a review from zeapoz April 23, 2024 13:19
@@ -52,6 +53,7 @@ impl SnapshotExporter {
.truncate(false)
.open(path)?;

header.generated_at = Utc::now();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit, but I would initialize this with the rest of the struct above i.e:

let mut header = SnapshotHeader {
    l1_batch_number,
    generated_at: Utc::now(),
    ..Default::default()
};

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK

@vbar vbar merged commit a8c46eb into main Apr 23, 2024
4 checks passed
@vbar vbar deleted the fix/set-generated-at branch April 23, 2024 13:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants