Checking if adding comments is allowed
Closed this issue · 1 comments
GajdosGabriel commented
I use the getCommentThreadsByVideoId () function
The problem is that some videos have comments turned off, and then the cycle stops with an error
Exception
Error 403 The video identified by the videoId
parameter has disabled comments. : commentsDisabled
How can I avoid this by checking if adding comments is allowed?
Thank you for a great extension.
alaouy commented
@GajdosGabriel You will need to use a try catch block https://www.php.net/manual/en/language.exceptions.php in order to handle that case.