Skip to content

Commit

Permalink
Bug fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
tjkessler committed Sep 2, 2023
1 parent c860f60 commit 86a96c6
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions plemmy/responses.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,8 +238,9 @@ class GetPersonDetailsResponse(object):
def __init__(self, api_response: requests.Response) -> None:

response = api_response.json()
self.comments = CommentView(response["comments"])
self.moderates = CommunityModeratorView(response["moderates"])
self.comments = [CommentView(c) for c in response["comments"]]
self.moderates = [CommunityModeratorView(m)
for m in response["moderates"]]
self.person_view = PersonView(response["person_view"])
self.posts = [PostView(p) for p in response["posts"]]

Expand All @@ -261,7 +262,8 @@ def __init__(self, api_response: requests.Response) -> None:
response = api_response.json()
self.community_view = CommunityView(response["community_view"])
self.cross_posts = [PostView(p) for p in response["cross_posts"]]
self.moderators = [CommunityModeratorView(m) for m in response["moderators"]]
self.moderators = [CommunityModeratorView(m)
for m in response["moderators"]]
self.post_view = PostView(response["post_view"])


Expand Down

0 comments on commit 86a96c6

Please sign in to comment.