Skip to content

Commit 646e427

Browse files
egpastmarcshilling
authored andcommitted
Android: fix cancellation handling (react-native-image-picker#506)
- This was broken by react-native-image-picker#496. - Currently, the response object is empty, lacking the `didCancel` flag.
1 parent dca64f1 commit 646e427

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

android/src/main/java/com/imagepicker/ImagePickerModule.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -307,7 +307,7 @@ public void onActivityResult(Activity activity, int requestCode, int resultCode,
307307

308308
// user cancel
309309
if (resultCode != Activity.RESULT_OK) {
310-
responseHelper.invokeResponse(callback);
310+
responseHelper.invokeCancel(callback);
311311
callback = null;
312312
return;
313313
}

0 commit comments

Comments
 (0)