Skip to content

Commit

Permalink
fix docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Szegoo committed Aug 23, 2024
1 parent 5c61e9d commit 40d8902
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
7 changes: 3 additions & 4 deletions pallets/orders/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -297,10 +297,9 @@ pub mod pallet {
}

fn order_expired(order: &Order<T::AccountId>) -> bool {
// Allowing order cancellation 1 timeslice before it truly expires makes writing
// benchmarks much easier. With this we can set the start and end to 0 and be able to
// cancel the order without having to modify the current timeslice.

// Defining the order expiry 1 timeslice before it truly expires makes writing
// benchmarks much easier. With this approach, we can set the start and end to 0,
// thereby defining the order as expired, to allow actions like order cancellation.
#[cfg(feature = "runtime-benchmarks")]
return order.requirements.end <= Self::current_timeslice();

Expand Down
2 changes: 1 addition & 1 deletion pallets/processor/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ pub mod pallet {
NotOwner,
/// We didn't find the task to which the region is supposed to be assigned.
RegionAssignmentNotFound,
/// The order user tried to fulfill expired.
/// The order expired and can't be fulfilled.
OrderExpired,
}

Expand Down

0 comments on commit 40d8902

Please sign in to comment.