parent
ff79646dd3
commit
5f2193b2c5
|
@ -196,6 +196,7 @@ proc decodeSuggestedFeesDto*(jsonObj: JsonNode): SuggestedFeesDto =
|
|||
result.maxFeePerGasL = jsonObj{"maxFeePerGasL"}.getFloat
|
||||
result.maxFeePerGasM = jsonObj{"maxFeePerGasM"}.getFloat
|
||||
result.maxFeePerGasH = jsonObj{"maxFeePerGasH"}.getFloat
|
||||
if jsonObj.hasKey("l1GasFee"):
|
||||
result.l1GasFee = jsonObj{"l1GasFee"}.getFloat
|
||||
result.eip1559Enabled = jsonObj{"eip1559Enabled"}.getbool
|
||||
|
||||
|
@ -207,6 +208,7 @@ proc toSuggestedFeesDto*(jsonObj: JsonNode): SuggestedFeesDto =
|
|||
result.maxFeePerGasL = parseFloat(jsonObj{"maxFeePerGasLow"}.getStr)
|
||||
result.maxFeePerGasM = parseFloat(jsonObj{"maxFeePerGasMedium"}.getStr)
|
||||
result.maxFeePerGasH = parseFloat(jsonObj{"maxFeePerGasHigh"}.getStr)
|
||||
if jsonObj.hasKey("l1GasFee"):
|
||||
result.l1GasFee = parseFloat(jsonObj{"l1GasFee"}.getStr)
|
||||
result.eip1559Enabled = jsonObj{"eip1559Enabled"}.getbool
|
||||
|
||||
|
|
Loading…
Reference in New Issue