Skip to content

Commit

Permalink
Merge pull request #6 from frenberg/chore/catch_npe_and_reject
Browse files Browse the repository at this point in the history
fix(android) NPE crash on bitmap, catch and reject
  • Loading branch information
frenberg authored Oct 6, 2023
2 parents c7066b1 + 7d09a75 commit e4336b7
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;

import static java.lang.String.format;

Expand Down Expand Up @@ -84,7 +83,7 @@ protected WritableMap doInBackground(Void... ignored) {
document.writeTo(new FileOutputStream(filePath));

result.putString("filePath", filePath.getAbsolutePath());
} catch (IOException e) {
} catch (Exception e) {
document.close();
return null;
}
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "react-native-image-to-pdf",
"version": "1.3.0",
"version": "1.3.1",
"description": "Converts images to a PDF file",
"main": "index.js",
"scripts": {
Expand Down

0 comments on commit e4336b7

Please sign in to comment.