Skip to content

Commit 1b1d19c

Browse files
committed
fix: use the correct timestamp check
Signed-off-by: Gustavo Inacio <[email protected]>
1 parent e5dfb0f commit 1b1d19c

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

tap_core/src/checks/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ impl Check for TimestampCheck {
5959
async fn check(&self, receipt: &ReceiptWithState<Checking>) -> CheckResult {
6060
let min_timestamp_ns = *self.min_timestamp_ns.read().unwrap();
6161
let signed_receipt = receipt.signed_receipt();
62-
if signed_receipt.message.timestamp_ns < min_timestamp_ns {
62+
if signed_receipt.message.timestamp_ns <= min_timestamp_ns {
6363
return Err(ReceiptError::InvalidTimestamp {
6464
received_timestamp: signed_receipt.message.timestamp_ns,
6565
timestamp_min: min_timestamp_ns,

tap_integration_tests/tests/showcase.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,13 +187,12 @@ fn executor(
187187
escrow_storage.clone(),
188188
timestamp_check.clone(),
189189
);
190-
let mut checks = get_full_list_of_checks(
190+
let checks = get_full_list_of_checks(
191191
domain_separator,
192192
sender_ids.iter().cloned().collect(),
193193
Arc::new(RwLock::new(allocation_ids.iter().cloned().collect())),
194194
query_appraisals,
195195
);
196-
checks.push(timestamp_check);
197196

198197
let checks = Checks::new(checks);
199198

0 commit comments

Comments
 (0)