pgrimaud / instagram-user-feed

This is a scrapper to easily fetch any feed and interact with Instagram (like, follow, etc.) without OAuth for PHP.
MIT License
882 stars 138 forks source link

MediaDetailed getDisplaySrc return null Value wheeras typing is string #236

Closed n-richaud closed 3 years ago

n-richaud commented 3 years ago

Version(s) affected: 6.8.0

Description
When trying to fetch nikefootball instgram (id : 23678829 ) the media of type GraphVideo with id : 2653393490909939243 and shortcode CTSv1JbBUYr , trigger a warning because the displaySrc field is empty whereas the typeHint make it mandatory. The Media is part of a sideCar Post

How to reproduce
Fetch Media with this link 'https://www.instagram.com/p/CTSv3j1hGIh/' using getMediaDetailed Possible Solution
Made the field displaySrc nullable

Additional context
Instagram\Model\Media::getDisplaySrc(): Return value must be of type string, null returned

pgrimaud commented 3 years ago

Hello,

Thanks for the issue. I just fixed it on v6.9.0