Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

onSDKDismissedHandler wrong callback arguments values #620

Open
kchasiotis opened this issue Sep 1, 2021 · 3 comments · May be fixed by #868
Open

onSDKDismissedHandler wrong callback arguments values #620

kchasiotis opened this issue Sep 1, 2021 · 3 comments · May be fixed by #868
Assignees
Labels
WIP Work In Progress

Comments

@kchasiotis
Copy link

Steps to Reproduce the Problem

Show Feedback Form

BugReporting.showWithOptions(BugReporting.reportType.feedback, [
    BugReporting.option.emailFieldOptional,
]);

When the form is submitted listen for it

BugReporting.onSDKDismissedHandler(function(dismissType, reportType) {
    if (dismissType === 'SUBMIT' && reportType === 'feedback') {
        console.log('user feedback');
    }
    console.log('-----------');
    console.log(dismissType);
    console.log(reportType);
    console.log(Instabug.dismissType.submit);
    console.log(BugReporting.reportType.feedback);
});

Expected Behaviour

The following logs return integer values based on the types below

console.log(Instabug.dismissType.submit);
console.log(BugReporting.reportType.feedback);

dismissType

export enum dismissType {
  submit,
  cancel,
  addAttachment
}

reportType

enum reportType {
  bug,
  feedback,
  question
}

Actual Behaviour

dismissType gets the string value 'SUBMIT'
reportType gets the value 'feedback'

Instabug integration code

SDK Version

"version": "10.8.1"

React Native, iOS and Android Versions

"react": "17.0.1"

Android versions:

   ext {
        buildToolsVersion = "29.0.3"
        minSdkVersion = 21
        compileSdkVersion = 29
        targetSdkVersion = 29
        ndkVersion = "20.1.5948944"
    }

note: Tested on android only

Device Model

@MahmoudMehisen
Copy link
Contributor

@kchasiotis Thanks for reporting this. We'll look further into this and get back to you.

@kchasiotis
Copy link
Author

@MahmoudMehisen cool, thank you!

@TheBuggedYRN TheBuggedYRN linked a pull request Dec 28, 2022 that will close this issue
7 tasks
@TheBuggedYRN TheBuggedYRN linked a pull request Jan 15, 2023 that will close this issue
7 tasks
@stale
Copy link

stale bot commented Feb 20, 2023

This issue has been automatically marked as pending feedback because we need additional information to be able to investigate it further. It will be closed in 7 days if it remains inactive. Thank you for your contributions.

@TheBuggedYRN TheBuggedYRN added WIP Work In Progress and removed Pending Feedback labels Feb 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
WIP Work In Progress
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants