You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At FetchPlugin.java line 123, when trying to check if response is a image if the response does not have ContentType it throw null pointer exception.
This changes address this issue for me
at line 123 i change from
if (response.body().contentType().type().equals("image")) {
to
if (response.body().contentType() != null && response.body().contentType().type().equals("image")) {
The text was updated successfully, but these errors were encountered:
leoleitemelo
changed the title
If response cody does not have ContentType plugin crash
If response body does not have ContentType plugin crash
Dec 2, 2022
leoleitemelo
added a commit
to leoleitemelo/cordova-plugin-fetch
that referenced
this issue
Dec 2, 2022
At FetchPlugin.java line 123, when trying to check if response is a image if the response does not have ContentType it throw null pointer exception.
This changes address this issue for me
at line 123 i change from
if (response.body().contentType().type().equals("image")) {
to
if (response.body().contentType() != null && response.body().contentType().type().equals("image")) {
The text was updated successfully, but these errors were encountered: