forked from zelo72/mastodon-ios
fix: follower list pagination not works issue
This commit is contained in:
parent
206beb6d19
commit
c9c0aaf148
|
@ -23,10 +23,15 @@ extension APIService {
|
|||
let authorization = authorizationBox.userAuthorization
|
||||
let requestMastodonUserID = authorizationBox.userID
|
||||
|
||||
let query = Mastodon.API.Account.FollowerQuery(
|
||||
maxID: maxID,
|
||||
limit: nil
|
||||
)
|
||||
return Mastodon.API.Account.followers(
|
||||
session: session,
|
||||
domain: domain,
|
||||
userID: userID,
|
||||
query: query,
|
||||
authorization: authorization
|
||||
)
|
||||
.flatMap { response -> AnyPublisher<Mastodon.Response.Content<[Mastodon.Entity.Account]>, Error> in
|
||||
|
|
|
@ -35,11 +35,12 @@ extension Mastodon.API.Account {
|
|||
session: URLSession,
|
||||
domain: String,
|
||||
userID: Mastodon.Entity.Account.ID,
|
||||
query: FollowerQuery,
|
||||
authorization: Mastodon.API.OAuth.Authorization
|
||||
) -> AnyPublisher<Mastodon.Response.Content<[Mastodon.Entity.Account]>, Error> {
|
||||
let request = Mastodon.API.get(
|
||||
url: followersEndpointURL(domain: domain, userID: userID),
|
||||
query: nil,
|
||||
query: query,
|
||||
authorization: authorization
|
||||
)
|
||||
return session.dataTaskPublisher(for: request)
|
||||
|
|
Loading…
Reference in New Issue