diff --git a/ledger/allegra/pparams.go b/ledger/allegra/pparams.go index 4c255df7..f25c54f3 100644 --- a/ledger/allegra/pparams.go +++ b/ledger/allegra/pparams.go @@ -29,3 +29,7 @@ func (p *AllegraProtocolParameters) Update(paramUpdate *AllegraProtocolParameter type AllegraProtocolParameterUpdate struct { shelley.ShelleyProtocolParameterUpdate } + +func (u *AllegraProtocolParameterUpdate) UnmarshalCBOR(data []byte) error { + return u.UnmarshalCbor(data, u) +} diff --git a/ledger/alonzo/alonzo.go b/ledger/alonzo/alonzo.go index cef02a49..71ae5ffb 100644 --- a/ledger/alonzo/alonzo.go +++ b/ledger/alonzo/alonzo.go @@ -513,6 +513,10 @@ type AlonzoProtocolParameterUpdate struct { MaxCollateralInputs uint `cbor:"24,keyasint"` } +func (u *AlonzoProtocolParameterUpdate) UnmarshalCBOR(data []byte) error { + return u.UnmarshalCbor(data, u) +} + func NewAlonzoBlockFromCbor(data []byte) (*AlonzoBlock, error) { var alonzoBlock AlonzoBlock if _, err := cbor.Decode(data, &alonzoBlock); err != nil { diff --git a/ledger/conway/conway.go b/ledger/conway/conway.go index 50864ad5..f50e7466 100644 --- a/ledger/conway/conway.go +++ b/ledger/conway/conway.go @@ -279,6 +279,10 @@ type ConwayProtocolParameterUpdate struct { MinFeeRefScriptCostPerByte *cbor.Rat `cbor:"33,keyasint"` } +func (u *ConwayProtocolParameterUpdate) UnmarshalCBOR(data []byte) error { + return u.UnmarshalCbor(data, u) +} + type PoolVotingThresholds struct { cbor.StructAsArray MotionNoConfidence cbor.Rat diff --git a/ledger/mary/pparams.go b/ledger/mary/pparams.go index 595019f9..12b14e2d 100644 --- a/ledger/mary/pparams.go +++ b/ledger/mary/pparams.go @@ -29,3 +29,7 @@ func (p *MaryProtocolParameters) Update(paramUpdate *MaryProtocolParameterUpdate type MaryProtocolParameterUpdate struct { allegra.AllegraProtocolParameterUpdate } + +func (u *MaryProtocolParameterUpdate) UnmarshalCBOR(data []byte) error { + return u.UnmarshalCbor(data, u) +}