@@ -84,7 +84,7 @@ module.exports = {
84
84
* Sets a block of code to be executed before sending each report.
85
85
* This block is executed in the background before sending each report. Could
86
86
* be used for attaching logs and extra data to reports.
87
- * @param {preSendingHandler } preSendingHandler - A callback that gets executed before sending each bug
87
+ * @param {function } preSendingHandler - A callback that gets executed before sending each bug
88
88
* report.
89
89
*/
90
90
setPreSendingHandler : function ( preSendingHandler ) {
@@ -105,7 +105,7 @@ module.exports = {
105
105
* Sets a block of code to be executed just before the SDK's UI is presented.
106
106
* This block is executed on the UI thread. Could be used for performing any
107
107
* UI changes before the SDK's UI is shown.
108
- * @param {preInvocationHandler } preInvocationHandler - A callback that gets executed before invoking the SDK
108
+ * @param {function } preInvocationHandler - A callback that gets executed before invoking the SDK
109
109
*/
110
110
setPreInvocationHandler : function ( preInvocationHandler ) {
111
111
if ( Platform . OS === 'ios' ) {
@@ -124,7 +124,7 @@ module.exports = {
124
124
* Sets a block of code to be executed right after the SDK's UI is dismissed.
125
125
* This block is executed on the UI thread. Could be used for performing any
126
126
* UI changes after the SDK's UI is dismissed.
127
- * @param {postInvocationHandler } postInvocationHandler - A callback to get executed after
127
+ * @param {function } postInvocationHandler - A callback to get executed after
128
128
* dismissing the SDK.
129
129
*/
130
130
setPostInvocationHandler : function ( postInvocationHandler ) {
@@ -376,15 +376,15 @@ module.exports = {
376
376
377
377
/**
378
378
* Sets a block of code that gets executed when a new message is received.
379
- * @param {onNewMessgaeHandler } onNewMessageHandler - A callback that gets
379
+ * @param {function } onNewMessageHandler - A callback that gets
380
380
* executed when a new message is received.
381
381
*/
382
382
setOnNewMessageHandler : function ( onNewMessageHandler ) {
383
383
if ( Platform . OS === 'ios' ) {
384
384
Instabug . addListener ( 'IBGonNewMessageHandler' ) ;
385
385
NativeAppEventEmitter . addListener (
386
386
'IBGonNewMessageHandler' ,
387
- onNewMessgaeHandler
387
+ onNewMessageHandler
388
388
) ;
389
389
}
390
390
@@ -399,7 +399,7 @@ module.exports = {
399
399
* you should call didReceiveRemoteNotification: to let the Instabug handle
400
400
* the notification. Otherwise, handle the notification on your own.
401
401
* @param {Object } dict Notification's userInfo
402
- * @param {isInstabugNotificationCallback } isInstabugNotificationCallback callback with
402
+ * @param {function } isInstabugNotificationCallback callback with
403
403
* argument isInstabugNotification
404
404
*/
405
405
isInstabugNotification : function ( dict , isInstabugNotificationCallback ) {
@@ -435,7 +435,7 @@ module.exports = {
435
435
* feedback.
436
436
* Use this method to give users a list of choices of categories their bug report or feedback might be related
437
437
* to. Selected category will be shown as a tag on your dashboard.
438
- * @param {array } titles titles to be shown in the list.
438
+ * @param {Array } titles titles to be shown in the list.
439
439
*/
440
440
setReportCategories : function ( ...titles ) {
441
441
if ( Platform . OS == 'ios' ) {
@@ -590,7 +590,7 @@ module.exports = {
590
590
* Returns the user attribute associated with a given key.
591
591
aKey
592
592
* @param {string } key The attribute key as string
593
- * @param {userAttributeCallback } userAttributeCallback callback with argument as the desired user attribute value
593
+ * @param {function } userAttributeCallback callback with argument as the desired user attribute value
594
594
*/
595
595
getUserAttribute : function ( key , userAttributeCallback ) {
596
596
Instabug . getUserAttribute ( key , userAttributeCallback ) ;
@@ -610,7 +610,7 @@ module.exports = {
610
610
611
611
/**
612
612
* @summary Returns all user attributes.
613
- * @param {userAttributesCallback } userAttributesCallback callback with argument A new dictionary containing all the currently set user attributes,
613
+ * @param {function } userAttributesCallback callback with argument A new dictionary containing all the currently set user attributes,
614
614
* or an empty dictionary if no user attributes have been set.
615
615
*/
616
616
getAllUserAttributes : function ( userAttributesCallback ) {
@@ -626,10 +626,12 @@ module.exports = {
626
626
627
627
/**
628
628
* @summary Enables/disables inspect view hierarchy when reporting a bug/feedback.
629
- * @param {boolean } viewHirearchyEnabled A boolean to set whether view hierarchy are enabled or disabled.
629
+ * @param {boolean } viewHierarchyEnabled A boolean to set whether view hierarchy are enabled or disabled.
630
630
*/
631
- setViewHirearchyEnabled : function ( viewHirearchyEnabled ) {
632
- Instabug . setViewHirearchyEnabled ( viewHirearchyEnabled ) ;
631
+ setViewHierarchyEnabled : function ( viewHierarchyEnabled ) {
632
+ if ( Platform . OS === 'ios' ) {
633
+ Instabug . setViewHierarchyEnabled ( viewHierarchyEnabled ) ;
634
+ }
633
635
} ,
634
636
635
637
/**
@@ -638,7 +640,7 @@ module.exports = {
638
640
* those surveys are still going to be sent to the device, but are not going to be shown automatically.
639
641
* To manually display any available surveys, call `Instabug.showSurveyIfAvailable()`.
640
642
* Defaults to `true`.
641
- * @param {boolean } viewHirearchyEnabled A boolean to set whether view hierarchy are enabled or disabled.
643
+ * @param {boolean } surveysEnabled A boolean to set whether Instabug Surveys is enabled or disabled.
642
644
*/
643
645
setSurveysEnabled : function ( surveysEnabled ) {
644
646
Instabug . setSurveysEnabled ( surveysEnabled )
@@ -656,7 +658,7 @@ module.exports = {
656
658
* @summary Sets a block of code to be executed just before the survey's UI is presented.
657
659
* This block is executed on the UI thread. Could be used for performing any UI changes before
658
660
* the survey's UI is shown.
659
- * @param {willShowSurveyHandler } willShowSurveyHandler - A block of code that gets executed before presenting the survey's UI.
661
+ * @param {function } willShowSurveyHandler - A block of code that gets executed before presenting the survey's UI.
660
662
* report.
661
663
*/
662
664
setWillShowSurveyHandler : function ( willShowSurveyHandler ) {
@@ -676,7 +678,7 @@ module.exports = {
676
678
* @summary Sets a block of code to be executed right after the survey's UI is dismissed.
677
679
* This block is executed on the UI thread. Could be used for performing any UI changes after the survey's UI
678
680
* is dismissed.
679
- * @param {didDismissSurveyHandler } didDismissSurveyHandler - A block of code that gets executed after the survey's UI is dismissed.
681
+ * @param {function } didDismissSurveyHandler - A block of code that gets executed after the survey's UI is dismissed.
680
682
*/
681
683
setDidDismissSurveyHandler : function ( didDismissSurveyHandler ) {
682
684
if ( Platform . OS === 'ios' ) {
0 commit comments