File tree Expand file tree Collapse file tree 2 files changed +18
-0
lines changed
android/src/main/java/com/instabug/reactlibrary Expand file tree Collapse file tree 2 files changed +18
-0
lines changed Original file line number Diff line number Diff line change @@ -320,6 +320,22 @@ public ArrayList<String> getTags() {
320
320
return tags ;
321
321
}
322
322
323
+ /**
324
+ * Set the user identity.
325
+ * Instabug will pre-fill the user email in reports.
326
+ *
327
+ * @param username Username.
328
+ * @param email User's default email
329
+ */
330
+ @ ReactMethod
331
+ public void identifyUser (String userName , String userEmail ) {
332
+ try {
333
+ mInstabug .identifyUser (userName , userEmail );
334
+ } catch (Exception e ) {
335
+ e .printStackTrace ();
336
+ }
337
+ }
338
+
323
339
/**
324
340
* Reset ALL tags added using {@link #addTags(String...)}
325
341
*/
Original file line number Diff line number Diff line change @@ -437,6 +437,8 @@ module.exports = {
437
437
identifyUserWithEmail : function ( email , name ) {
438
438
if ( Platform . OS == 'ios' ) {
439
439
Instabug . identifyUserWithEmail ( email , name ) ;
440
+ } else if ( 'android' ) {
441
+ Instabug . identifyUser ( name , email ) ;
440
442
}
441
443
} ,
442
444
You can’t perform that action at this time.
0 commit comments