fix: handle non-existent rottentomatoes rating for movies (#1169)

This fixes a bug where some movies don't have any rottentomatoes
ratings, which causes ratings from other services to not show
This commit is contained in:
Ben Haney
2024-12-20 04:23:14 -06:00
committed by GitHub
parent 66a5ab41ab
commit 347a24a97b

View File

@@ -128,7 +128,7 @@ class RottenTomatoes extends ExternalAPI {
movie = contentResults.hits.find((movie) => movie.title === name);
}
if (!movie) {
if (!movie?.rottenTomatoes) {
return null;
}