Skip to content

Commit

Permalink
lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
manojkgorle committed Jan 21, 2025
1 parent 6070065 commit 04d7ff5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions actions/auction.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ type AuctionInfo struct {
BuilderSEQAddress codec.Address `json:"builderSEQAddress"`
}

func (a *AuctionInfo) HashAuctionInfo() ([32]byte, error) {
msg := binary.BigEndian.AppendUint64(nil, a.EpochNumber)
msg = binary.BigEndian.AppendUint64(msg, a.BidPrice)
msg = append(msg, a.BuilderSEQAddress[:]...)
func (info *AuctionInfo) HashAuctionInfo() ([32]byte, error) {
msg := binary.BigEndian.AppendUint64(nil, info.EpochNumber)
msg = binary.BigEndian.AppendUint64(msg, info.BidPrice)
msg = append(msg, info.BuilderSEQAddress[:]...)
hash := sha256.Sum256(msg)
return hash, nil
}
Expand Down
2 changes: 1 addition & 1 deletion actions/rollup_register.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func (r *RollupRegistration) Execute(
} else {
// only allow modifing informations that are not related to ExitEpoch or StartEpoch
if err := authorizationChecks(ctx, actor, namespaces, r.Namespace, mu); err != nil {
return nil, fmt.Errorf("authorization failed: %s", err.Error())
return nil, fmt.Errorf("authorization failed: %w", err)
}
}
if r.Info.StartEpoch < Epoch(hght, rules.GetEpochLength())+2 || r.Info.ExitEpoch != 0 {
Expand Down

0 comments on commit 04d7ff5

Please sign in to comment.