instagram-user-feed
instagram-user-feed copied to clipboard
No followers - getEndCursor() is null
Version(s) affected: 6.16.4
Description
Followers are no longer output because the endcursor is null:
object(Instagram\Model\FollowerFeed)#7 (4) { ["count":"Instagram\Model\FollowerFeed":private]=> int(957) ["hasNextPage":"Instagram\Model\FollowerFeed":private]=> bool(false) ["endCursor":"Instagram\Model\FollowerFeed":private]=> NULL ["users":"Instagram\Model\FollowerFeed":private]=> array(0) { } }
Fatal error: Uncaught TypeError: Argument 2 passed to Instagram\Api::getMoreFollowers() must be of the type string, null given
How to reproduce
$followersFeed = $this->api->getFollowers(self::IG_USER_ID);
var_dump($followersFeed);
do {
$followersFeed = $this->api->getMoreFollowers(self::IG_USER_ID, $followersFeed->getEndCursor());
sleep(2);
} while ($followersFeed->hasNextPage());
Hello,
Happy new year to all of you.
I've the same issue. When I inspect requests from Instagram website, the request is :
https://www.instagram.com/api/v1/friendships/XXXX/followers/?count=12&search_surface=follow_list_page
Maybe this can help.
problem solved?
@melnichukme No, the problem is still here
This is the graphql response :
@babeuloula problem with instagram api?
Yes with this call : https://github.com/pgrimaud/instagram-user-feed/blob/03762f186804ce5d20cfc0649e5c99b693225e4f/src/Instagram/Transport/JsonFollowerDataFeed.php#L28
Hello, got the same issue , followers is empty
It happens to me with getMedias(), it returns an empty array.