1212from xrpl .core .binarycodec .exceptions import XRPLBinaryCodecException
1313from xrpl .core .binarycodec .types .account_id import AccountID
1414from xrpl .core .binarycodec .types .currency import Currency
15- from xrpl .core .binarycodec .types .hash192 import Hash192
15+ from xrpl .core .binarycodec .types .hash192 import HASH192_BYTES , Hash192
1616from xrpl .core .binarycodec .types .serialized_type import SerializedType
1717
1818# Constant for masking types of a PathStep
2121_TYPE_ISSUER : Final [int ] = 0x20
2222_TYPE_MPT : Final [int ] = 0x40
2323
24- _HASH192_BYTES : Final [int ] = 24
25-
2624# Constants for separating Paths in a PathSet
2725_PATHSET_END_BYTE : Final [int ] = 0x00
2826_PATH_SEPARATOR_BYTE : Final [int ] = 0xFF
@@ -121,7 +119,7 @@ def from_parser(
121119 currency = parser .read (Currency .LENGTH )
122120 buffer += currency
123121 elif data_type & _TYPE_MPT :
124- mpt_id = parser .read (_HASH192_BYTES )
122+ mpt_id = parser .read (HASH192_BYTES )
125123 buffer += mpt_id
126124 if data_type & _TYPE_ISSUER :
127125 issuer = parser .read (AccountID .LENGTH )
@@ -147,7 +145,7 @@ def to_json(self: Self) -> Dict[str, str]:
147145 currency = Currency .from_parser (parser ).to_json ()
148146 json ["currency" ] = currency
149147 elif data_type & _TYPE_MPT :
150- mpt_id = parser .read (_HASH192_BYTES ).hex ().upper ()
148+ mpt_id = parser .read (HASH192_BYTES ).hex ().upper ()
151149 json ["mpt_issuance_id" ] = mpt_id
152150 if data_type & _TYPE_ISSUER :
153151 issuer = AccountID .from_parser (parser ).to_json ()
0 commit comments