Commit 8638584
Changed files (1)
src
history
src/history/turso.py
@@ -162,7 +162,7 @@ async def upload_exported_history_to_turso(client: Client, path: str | Path | No
dt = datetime.fromtimestamp(int(info["date_unixtime"]), tz=ZoneInfo(TZ))
uid = int(info["from_id"].removeprefix("user").removeprefix("channel"))
- user = info["from"]
+ user = info["from"] or info["from_id"].removeprefix("user").removeprefix("channel")
if user == data["name"] and data["type"] in ["public_channel", "private_channel"]: # user is not shown
user = ""
uid = 1