fix bluesky login display

This commit is contained in:
Your Name 2024-07-05 22:01:04 -04:00 committed by Henri Dickson
parent e29dc521e2
commit cbc4c8de77
2 changed files with 6 additions and 7 deletions

View file

@ -158,9 +158,11 @@ class BlueskyAccount(SocialAccount):
logger.warning("Bluesky: client not logged in.") # this should not happen
return False
if self.handle != profile.handle:
if self.handle:
logger.warning(
f"ATProto refresh: handle mismatch {self.handle} from did doc -> {profile.handle} from PDS"
)
self.handle = profile.handle
self.account_data = {
k: v for k, v in profile.__dict__.items() if isinstance(v, (int, str))
}

View file

@ -82,15 +82,12 @@ class SocialAccount(TypedModel):
for k, v in self.__dict__.items()
if k
not in [
"_state",
"_client",
"_profile",
"api_domain",
"created",
"modified",
"last_refresh",
"last_reachable",
]
and not k.startswith("_")
}
return d