Skip to content

Commit 43c161e

Browse files
committed
📝 Change parameters names for callback response for postInvocationHandler
1 parent 3f4a65f commit 43c161e

File tree

2 files changed

+3
-13
lines changed

2 files changed

+3
-13
lines changed

‎android/src/main/java/com/instabug/reactlibrary/RNInstabugReactnativeModule.java

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1303,22 +1303,12 @@ public void onReportCreated(Report report) {
13031303
@ReactMethod
13041304
public void setPostInvocationHandler(final Callback postInvocationHandler) {
13051305
try {
1306-
// BugReporting.setOnDismissCallback(new OnSdkDismissCallback() {
1307-
// @Override
1308-
// public void call() {
1309-
//// WritableMap params = Arguments.createMap();
1310-
//// params.putString("issueState", issueState.toString());
1311-
//// params.putString("bugType", bugType.toString());
1312-
// sendEvent(getReactApplicationContext(), "IBGpostInvocationHandler", null);
1313-
// }
1314-
// });
1315-
13161306
BugReporting.setOnDismissCallback(new OnSdkDismissCallback() {
13171307
@Override
13181308
public void call(DismissType dismissType, ReportType reportType) {
13191309
WritableMap params = Arguments.createMap();
1320-
params.putString("issueState", dismissType.toString());
1321-
params.putString("bugType", reportType.toString());
1310+
params.putString("dismissType", dismissType.toString());
1311+
params.putString("reportType", reportType.toString());
13221312
sendEvent(getReactApplicationContext(), "IBGpostInvocationHandler", null);
13231313
}
13241314
});

‎index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,7 @@ module.exports = {
262262
);
263263
} else {
264264
DeviceEventEmitter.addListener('IBGpostInvocationHandler', function(payload) {
265-
postInvocationHandler(payload.issueState, payload.bugType);
265+
postInvocationHandler(payload.dismissType, payload.reportType);
266266
});
267267
}
268268

0 commit comments

Comments
 (0)