Refine admin update clarity for phone extraction and reset strategy

Agent-Logs-Url: https://github.com/kr0sh512/tt-simple/sessions/34c3052e-7b55-4cb8-9fee-0ee1ba315691

Co-authored-by: kr0sh512 <46405586+kr0sh512@users.noreply.github.com>
This commit is contained in:
copilot-swe-agent[bot]
2026-04-21 12:07:46 +00:00
committed by GitHub
co-authored by kr0sh512
parent 6553e4b5ff
commit 7eb57b788b
+2 -4
View File
@@ -359,7 +359,7 @@ class VpnBot:
lock = self.locks.setdefault(message.from_user.id, asyncio.Lock())
order_info = getattr(payment, "order_info", None)
phone = getattr(order_info, "phone_number", None)
phone = getattr(order_info, "phone_number", None) if order_info else None
async with lock:
info = await self.buy_or_extend(message.from_user, months, phone)
@@ -400,9 +400,7 @@ class VpnBot:
expire_at = add_months(expire_from, months)
data_limit = int(current.get("data_limit", 50 * GB)) if current else 50 * GB
data_limit_reset_strategy = (
current.get("data_limit_reset_strategy") or "month"
) if current else "month"
data_limit_reset_strategy = (current.get("data_limit_reset_strategy") if current else None) or "month"
note = current.get("note") if current else self._format_new_user_note(
user.first_name, user.last_name, phone
)