Skip to content
This repository has been archived by the owner on Dec 12, 2024. It is now read-only.

Commit

Permalink
Undo build failure test, fix linting
Browse files Browse the repository at this point in the history
  • Loading branch information
KendallWeihe committed Apr 29, 2024
1 parent c0d24ce commit ca108cc
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 14 deletions.
2 changes: 0 additions & 2 deletions crates/protocol/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
pub mod message;
pub mod resource;

hello

#[cfg(test)]
pub mod test_data;
2 changes: 1 addition & 1 deletion crates/protocol/src/message/close.rs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ impl Close {
to,
kind: MessageKind::Close,
id: MessageKind::Close.typesafe_id()?,
exchange_id: exchange_id,
exchange_id,
created_at: Utc::now(),
};

Expand Down
2 changes: 1 addition & 1 deletion crates/protocol/src/message/order.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ impl Order {
to,
kind: MessageKind::Order,
id: MessageKind::Order.typesafe_id()?,
exchange_id: exchange_id,
exchange_id,
created_at: Utc::now(),
};

Expand Down
2 changes: 1 addition & 1 deletion crates/protocol/src/message/order_status.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ impl OrderStatus {
to,
kind: MessageKind::OrderStatus,
id: MessageKind::OrderStatus.typesafe_id()?,
exchange_id: exchange_id,
exchange_id,
created_at: Utc::now(),
};

Expand Down
15 changes: 6 additions & 9 deletions crates/protocol/src/resource/offering.rs
Original file line number Diff line number Diff line change
Expand Up @@ -82,15 +82,12 @@ pub struct PaymentMethod {

impl PaymentMethod {
pub fn required_payment_details_schema(&self) -> Option<JSONSchema> {
self.required_payment_details
.as_ref()
.map(|json| {
JSONSchema::options()
.with_draft(Draft::Draft7)
.compile(json)
.ok()
})
.flatten()
self.required_payment_details.as_ref().and_then(|json| {
JSONSchema::options()
.with_draft(Draft::Draft7)
.compile(json)
.ok()
})
}
}

Expand Down

0 comments on commit ca108cc

Please sign in to comment.