Skip to content

Commit

Permalink
chore: make format golines
Browse files Browse the repository at this point in the history
Signed-off-by: Chris Gianelloni <wolf31o2@blinklabs.io>
  • Loading branch information
wolf31o2 committed Nov 9, 2024
1 parent 5a800b1 commit a076eba
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 7 deletions.
4 changes: 3 additions & 1 deletion ledger/allegra/pparams.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ func (p *AllegraProtocolParameters) Utxorpc() *cardano.PParams {
return p.ShelleyProtocolParameters.Utxorpc()
}

func UpgradePParams(prevPParams shelley.ShelleyProtocolParameters) AllegraProtocolParameters {
func UpgradePParams(
prevPParams shelley.ShelleyProtocolParameters,
) AllegraProtocolParameters {
return AllegraProtocolParameters{
ShelleyProtocolParameters: prevPParams,
}
Expand Down
4 changes: 3 additions & 1 deletion ledger/alonzo/pparams.go
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,9 @@ func (p *AlonzoProtocolParameters) Utxorpc() *cardano.PParams {
}
}

func UpgradePParams(prevPParams mary.MaryProtocolParameters) AlonzoProtocolParameters {
func UpgradePParams(
prevPParams mary.MaryProtocolParameters,
) AlonzoProtocolParameters {
return AlonzoProtocolParameters{
MaryProtocolParameters: prevPParams,
}
Expand Down
4 changes: 3 additions & 1 deletion ledger/babbage/pparams.go
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,9 @@ func (p *BabbageProtocolParameters) Utxorpc() *cardano.PParams {
}
}

func UpgradePParams(prevPParams alonzo.AlonzoProtocolParameters) BabbageProtocolParameters {
func UpgradePParams(
prevPParams alonzo.AlonzoProtocolParameters,
) BabbageProtocolParameters {
ret := BabbageProtocolParameters{
MinFeeA: prevPParams.MinFeeA,
MinFeeB: prevPParams.MinFeeB,
Expand Down
4 changes: 3 additions & 1 deletion ledger/conway/pparams.go
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,9 @@ type DRepVotingThresholds struct {
TreasuryWithdrawal cbor.Rat
}

func UpgradePParams(prevPParams babbage.BabbageProtocolParameters) ConwayProtocolParameters {
func UpgradePParams(
prevPParams babbage.BabbageProtocolParameters,
) ConwayProtocolParameters {
ret := ConwayProtocolParameters{
MinFeeA: prevPParams.MinFeeA,
MinFeeB: prevPParams.MinFeeB,
Expand Down
4 changes: 3 additions & 1 deletion ledger/mary/pparams.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ func (p *MaryProtocolParameters) Utxorpc() *cardano.PParams {
return p.AllegraProtocolParameters.Utxorpc()
}

func UpgradePParams(prevPParams allegra.AllegraProtocolParameters) MaryProtocolParameters {
func UpgradePParams(
prevPParams allegra.AllegraProtocolParameters,
) MaryProtocolParameters {
return MaryProtocolParameters{
AllegraProtocolParameters: prevPParams,
}
Expand Down
8 changes: 6 additions & 2 deletions protocol/handshake/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,9 @@ func (s *Server) handleProposeVersions(msg protocol.Message) error {
[]any{
RefuseReasonDecodeError,
proposedVersion,
fmt.Errorf("handshake failed: refused due to empty version data"),
fmt.Errorf(
"handshake failed: refused due to empty version data",
),
},
)
if err := s.SendMessage(msgRefuse); err != nil {
Expand Down Expand Up @@ -168,7 +170,9 @@ func (s *Server) handleProposeVersions(msg protocol.Message) error {
[]any{
RefuseReasonDecodeError,
proposedVersion,
fmt.Errorf("handshake failed: refused due to empty version map"),
fmt.Errorf(
"handshake failed: refused due to empty version map",
),
},
)
if err := s.SendMessage(msgRefuse); err != nil {
Expand Down

0 comments on commit a076eba

Please sign in to comment.