Skip to content

Commit

Permalink
avoid NPE seen on sentry
Browse files Browse the repository at this point in the history
  • Loading branch information
courville committed May 19, 2024
1 parent 1f40a45 commit f9694c3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/com/archos/mediascraper/themoviedb3/SearchMovie2.java
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public static SearchMovieResult search(String query, String language, String yea
if (response.isSuccessful()) {
if (response.body() != null) {
log.debug("search: response body has " + response.body().total_results + " results");
if (response.body().total_results == 0)
if (response.body().total_results != null && response.body().total_results == 0)
notFound = true;
parserResult = SearchMovieParser2.getResult(response, query, language, year, resultLimit);
myResult.result = parserResult;
Expand Down

0 comments on commit f9694c3

Please sign in to comment.