From 13ee45cd66a26d4f90a61b5dd89addbd387da5e3 Mon Sep 17 00:00:00 2001 From: jaykayudo Date: Fri, 25 Oct 2024 12:46:19 +0100 Subject: [PATCH] chore: add return types for methods --- data_handler/handler_tools/data_parser/serializers.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/data_handler/handler_tools/data_parser/serializers.py b/data_handler/handler_tools/data_parser/serializers.py index e8fc085c..eab6d721 100644 --- a/data_handler/handler_tools/data_parser/serializers.py +++ b/data_handler/handler_tools/data_parser/serializers.py @@ -28,7 +28,7 @@ class LiquidationEventData(BaseModel): collateral_amount: str @field_validator("liquidator", "user", "debt_token", "collateral_token") - def validate_valid_addresses(cls, value: str, info: ValidationInfo): + def validate_valid_addresses(cls, value: str, info: ValidationInfo) -> str: """ Check if the value is an address and format it to having leading zeros. @@ -43,7 +43,7 @@ def validate_valid_addresses(cls, value: str, info: ValidationInfo): return add_leading_zeros(value) @field_validator("debt_raw_amount", "debt_face_amount", "collateral_amount") - def validate_valid_numbers(cls, value: str, info: ValidationInfo): + def validate_valid_numbers(cls, value: str, info: ValidationInfo) -> Decimal: """ Check if the value is a digit and convert it to a decimal from base 16 int conversion.