Skip to content

Commit 5783d89

Browse files
Soupstrawlehins
andauthored
binaryGetDecoder code reuse
Co-authored-by: Alexey Kuleshevich <alexey.kuleshevich@iohk.io>
1 parent 1f96268 commit 5783d89

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

  • libs/cardano-ledger-binary/src/Cardano/Ledger/Binary/Decoding

libs/cardano-ledger-binary/src/Cardano/Ledger/Binary/Decoding/Decoder.hs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1325,11 +1325,7 @@ binaryGetDecoder ::
13251325
Get a ->
13261326
Decoder s a
13271327
binaryGetDecoder name getter = do
1328-
bs <-
1329-
ifDecoderVersionAtLeast
1330-
(natVersion @12)
1331-
decodeBytesDefOrIndef
1332-
decodeBytes
1328+
bs <- decCBOR
13331329
case runGetOrFail getter (BSL.fromStrict bs) of
13341330
Left (_, _, err) -> cborError $ DecoderErrorCustom name (Text.pack err)
13351331
Right (leftOver, _, ha)

0 commit comments

Comments
 (0)