Skip to content

Commit

Permalink
Some cleanup and comments
Browse files Browse the repository at this point in the history
  • Loading branch information
tbro committed Jun 25, 2024
1 parent 3618312 commit d2ba555
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions sequencer/src/auction.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ use thiserror::Error;
use url::Url;

#[derive(Debug, Clone, Eq, PartialEq, Deserialize, Serialize, Hash)]
// This is here to fill in for something I don't understand yet.
struct SequencerKey;

// for MVP-0(-1) (JIT)
Expand Down Expand Up @@ -104,7 +105,7 @@ pub struct BidTxBody {
/// The bid amount designated in Wei. This is different than
/// the sequencing fee (gas price) for this transaction
bid_amount: FeeAmount,
// TODO What is the correct type?
// TODO What is the correct type? What do we use this for?
/// The public key of this sequencer
public_key: SequencerKey,
/// The URL the HotShot leader will use to request a bundle
Expand Down Expand Up @@ -139,7 +140,7 @@ impl BidTxBody {
pub fn sign(&self, key: &EthKeyPair) -> Result<Signature, SigningError> {
FeeAccount::sign_builder_message(key, self.commit().as_ref())
}
/// Get account responsible for bid
/// Get account submitting the bid
pub fn account(&self) -> FeeAccount {
self.account
}
Expand Down Expand Up @@ -167,9 +168,8 @@ impl Default for BidTxBody {
impl Default for BidTx {
fn default() -> Self {
let body = BidTxBody::default();
let commitment = body.commit();
let key = FeeAccount::test_key_pair();
let signature = FeeAccount::sign_builder_message(&key, commitment.as_ref()).unwrap();
let signature = FeeAccount::sign_builder_message(&key, body.commit().as_ref()).unwrap();
Self { signature, body }
}
}
Expand Down

0 comments on commit d2ba555

Please sign in to comment.