-import { Component, OnInit } from '@angular/core'
-import { FollowService } from '@app/shared/instance/follow.service'
-import { ComponentPagination, hasMoreItems } from '@app/shared/rest/component-pagination.model'
-import { Notifier } from '@app/core'
-import { RestService } from '@app/shared'
import { SortMeta } from 'primeng/api'
import { Subject } from 'rxjs'
+import { Component, OnInit } from '@angular/core'
+import { ComponentPagination, hasMoreItems, Notifier, RestService } from '@app/core'
+import { InstanceFollowService } from '@app/shared/shared-instance'
@Component({
selector: 'my-about-follows',
constructor (
private restService: RestService,
private notifier: Notifier,
- private followService: FollowService
+ private followService: InstanceFollowService
) { }
ngOnInit () {
private loadMoreFollowers () {
const pagination = this.restService.componentPaginationToRestPagination(this.followersPagination)
- this.followService.getFollowers(pagination, this.sort)
+ this.followService.getFollowers({ pagination: pagination, sort: this.sort, state: 'accepted' })
.subscribe(
resultList => {
const newFollowers = resultList.data.map(r => r.follower.host)
private loadMoreFollowings () {
const pagination = this.restService.componentPaginationToRestPagination(this.followingsPagination)
- this.followService.getFollowing(pagination, this.sort)
+ this.followService.getFollowing({ pagination, sort: this.sort, state: 'accepted' })
.subscribe(
resultList => {
const newFollowings = resultList.data.map(r => r.following.host)