Skip to content

Commit

Permalink
[REGRESSION] #1362 Cannot view profile of user mentioned in post
Browse files Browse the repository at this point in the history
  • Loading branch information
whattherestimefor committed Nov 25, 2024
1 parent ac6157e commit 311bbc0
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
5 changes: 4 additions & 1 deletion Mastodon/Protocol/Provider/DataSourceFacade+Profile.swift
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,10 @@ extension DataSourceFacade {

do {
let account = try await APIService.shared.accountInfo(
provider.authenticationBox
domain: domain,
userID:
accountID,
authorization: provider.authenticationBox.userAuthorization
)

provider.coordinator.hideLoading()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,16 @@ extension APIService {
return account
}

public func accountInfo(domain: String, userID: String, authorization: Mastodon.API.OAuth.Authorization) async throws -> Mastodon.Entity.Account {
let account = try await Mastodon.API.Account.accountInfo(
session: session,
domain: domain,
userID: userID,
authorization: authorization
).singleOutput().value
return account
}

}

extension APIService {
Expand Down

0 comments on commit 311bbc0

Please sign in to comment.