@@ -84,7 +84,7 @@ module.exports = {
8484 * Sets a block of code to be executed before sending each report.
8585 * This block is executed in the background before sending each report. Could
8686 * 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
8888 * report.
8989 */
9090 setPreSendingHandler : function ( preSendingHandler ) {
@@ -105,7 +105,7 @@ module.exports = {
105105 * Sets a block of code to be executed just before the SDK's UI is presented.
106106 * This block is executed on the UI thread. Could be used for performing any
107107 * 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
109109 */
110110 setPreInvocationHandler : function ( preInvocationHandler ) {
111111 if ( Platform . OS === 'ios' ) {
@@ -124,7 +124,7 @@ module.exports = {
124124 * Sets a block of code to be executed right after the SDK's UI is dismissed.
125125 * This block is executed on the UI thread. Could be used for performing any
126126 * 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
128128 * dismissing the SDK.
129129 */
130130 setPostInvocationHandler : function ( postInvocationHandler ) {
@@ -376,15 +376,15 @@ module.exports = {
376376
377377 /**
378378 * 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
380380 * executed when a new message is received.
381381 */
382382 setOnNewMessageHandler : function ( onNewMessageHandler ) {
383383 if ( Platform . OS === 'ios' ) {
384384 Instabug . addListener ( 'IBGonNewMessageHandler' ) ;
385385 NativeAppEventEmitter . addListener (
386386 'IBGonNewMessageHandler' ,
387- onNewMessgaeHandler
387+ onNewMessageHandler
388388 ) ;
389389 }
390390
@@ -399,7 +399,7 @@ module.exports = {
399399 * you should call didReceiveRemoteNotification: to let the Instabug handle
400400 * the notification. Otherwise, handle the notification on your own.
401401 * @param {Object } dict Notification's userInfo
402- * @param {isInstabugNotificationCallback } isInstabugNotificationCallback callback with
402+ * @param {function } isInstabugNotificationCallback callback with
403403 * argument isInstabugNotification
404404 */
405405 isInstabugNotification : function ( dict , isInstabugNotificationCallback ) {
@@ -435,7 +435,7 @@ module.exports = {
435435 * feedback.
436436 * Use this method to give users a list of choices of categories their bug report or feedback might be related
437437 * 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.
439439 */
440440 setReportCategories : function ( ...titles ) {
441441 if ( Platform . OS == 'ios' ) {
@@ -590,7 +590,7 @@ module.exports = {
590590 * Returns the user attribute associated with a given key.
591591 aKey
592592 * @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
594594 */
595595 getUserAttribute : function ( key , userAttributeCallback ) {
596596 Instabug . getUserAttribute ( key , userAttributeCallback ) ;
@@ -610,7 +610,7 @@ module.exports = {
610610
611611 /**
612612 * @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,
614614 * or an empty dictionary if no user attributes have been set.
615615 */
616616 getAllUserAttributes : function ( userAttributesCallback ) {
@@ -626,10 +626,12 @@ module.exports = {
626626
627627 /**
628628 * @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.
630630 */
631- setViewHirearchyEnabled : function ( viewHirearchyEnabled ) {
632- Instabug . setViewHirearchyEnabled ( viewHirearchyEnabled ) ;
631+ setViewHierarchyEnabled : function ( viewHierarchyEnabled ) {
632+ if ( Platform . OS === 'ios' ) {
633+ Instabug . setViewHierarchyEnabled ( viewHierarchyEnabled ) ;
634+ }
633635 } ,
634636
635637 /**
@@ -638,7 +640,7 @@ module.exports = {
638640 * those surveys are still going to be sent to the device, but are not going to be shown automatically.
639641 * To manually display any available surveys, call `Instabug.showSurveyIfAvailable()`.
640642 * 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.
642644 */
643645 setSurveysEnabled : function ( surveysEnabled ) {
644646 Instabug . setSurveysEnabled ( surveysEnabled )
@@ -656,7 +658,7 @@ module.exports = {
656658 * @summary Sets a block of code to be executed just before the survey's UI is presented.
657659 * This block is executed on the UI thread. Could be used for performing any UI changes before
658660 * 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.
660662 * report.
661663 */
662664 setWillShowSurveyHandler : function ( willShowSurveyHandler ) {
@@ -676,7 +678,7 @@ module.exports = {
676678 * @summary Sets a block of code to be executed right after the survey's UI is dismissed.
677679 * This block is executed on the UI thread. Could be used for performing any UI changes after the survey's UI
678680 * 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.
680682 */
681683 setDidDismissSurveyHandler : function ( didDismissSurveyHandler ) {
682684 if ( Platform . OS === 'ios' ) {
0 commit comments