Merge pull request #2212 from BEDOLAGA-DEV/dev5

Update subscription_service.py
This commit is contained in:
Egor
2025-12-25 11:00:00 +03:00
committed by GitHub

View File

@@ -1238,8 +1238,8 @@ class SubscriptionService:
logger.info(f"Итого доплата за {months_to_pay} мес: {total_price/100}")
return total_price
def _gb_to_bytes(self, gb: int) -> int:
if gb == 0:
def _gb_to_bytes(self, gb: Optional[int]) -> int:
if not gb: # None or 0
return 0
return gb * 1024 * 1024 * 1024