πŸ“•
Custom data

Add custom data

In many situations you may want to attach custom data to bug reports in order to reproduce them more quickly. You can add custom data incrementally or all at once at one time. Any simple dictionary can be attached.
1
BugBattle.getInstance().setCustomData("[email protected]", "email");
Copied!

Append custom data

If you want to attach custom data incrementally you can do so with the attachUserAttribute method.
1
JSONObject jsonObject = new JSONObject();
2
BugBattle.getInstance().appendCustomData(jsonObject);
Copied!

Remove custom data

Remove custom data key value pairs by calling the following method.
1
BugBattle.getInstance().removeCustomDataForKey("email");
Copied!

Clear all custom data

It's possible to clear all attached custom data by calling the following method.
1
BugBattle.getInstance().clearCustomData();
Copied!
​
​
Last modified 3mo ago