1- //todo: remove all logs tagged with 'Andrew' in the file
21import {
32 AppState ,
43 type AppStateStatus ,
@@ -74,25 +73,6 @@ function reportCurrentViewForAndroid(screenName: string | null) {
7473 }
7574}
7675
77- function _logFlags ( ) {
78- if ( Platform . OS === 'android' ) {
79- console . log (
80- `Andrew: APM Flags -> {
81- isNativeInterceptionFeatureEnabled: ${ isNativeInterceptionFeatureEnabled } ,
82- hasAPMNetworkPlugin: ${ hasAPMNetworkPlugin } ,
83- shouldEnableNativeInterception: ${ shouldEnableNativeInterception }
84- }` ,
85- ) ;
86- } else {
87- console . log (
88- `Andrew: APM Flags -> {
89- isNativeInterceptionFeatureEnabled: ${ isNativeInterceptionFeatureEnabled } ,
90- shouldEnableNativeInterception: ${ shouldEnableNativeInterception }
91- }` ,
92- ) ;
93- }
94- }
95-
9676/**
9777 * Initializes the SDK.
9878 * This is the main SDK method that does all the magic. This is the only
@@ -148,14 +128,11 @@ const handleAppStateChange = async (nextAppState: AppStateStatus, config: Instab
148128 const isUpdated = await fetchApmNetworkFlags ( ) ;
149129
150130 if ( isUpdated ) {
151- console . log ( 'Andrew: App has come to the foreground!' ) ;
152- console . log ( 'Andrew: APM network flags updated.' ) ;
153131 refreshAPMNetworkConfigs ( config ) ;
154132 }
155133 }
156134
157135 _currentAppState = nextAppState ;
158- console . log ( `Andrew: Current AppState: ${ _currentAppState } ` ) ;
159136} ;
160137
161138/**
@@ -176,10 +153,6 @@ const fetchApmNetworkFlags = async () => {
176153 isUpdated = true ;
177154 }
178155 }
179-
180- console . log (
181- `Andrew: fetchApmNetworkFlags {isNativeInterceptionFeatureEnabled: ${ isNativeInterceptionFeatureEnabled } , hasAPMNetworkPlugin: ${ hasAPMNetworkPlugin } }` ,
182- ) ;
183156 return isUpdated ;
184157} ;
185158
@@ -241,13 +214,6 @@ function handleAndroidNativeInterception() {
241214 * Control either to enable or disable the native interception for iOS after the init method is called.
242215 */
243216function handleIOSNativeInterception ( config : InstabugConfig ) {
244- console . log (
245- `Andrew: handleIOSNativeInterception(${
246- shouldEnableNativeInterception &&
247- config . networkInterceptionMode === NetworkInterceptionMode . native
248- } )`,
249- ) ;
250-
251217 if (
252218 shouldEnableNativeInterception &&
253219 config . networkInterceptionMode === NetworkInterceptionMode . native
@@ -295,12 +261,6 @@ const handleInterceptionModeForIOS = (config: InstabugConfig) => {
295261 * Initializes Instabug with the given configuration.
296262 */
297263const initializeNativeInstabug = ( config : InstabugConfig ) => {
298- console . log (
299- `Andrew: initializeNativeInstabug -> NativeNetworkInterceptionMode ${
300- shouldEnableNativeInterception &&
301- config . networkInterceptionMode === NetworkInterceptionMode . native
302- } `,
303- ) ;
304264 NativeInstabug . init (
305265 config . token ,
306266 config . invocationEvents ,
@@ -319,7 +279,6 @@ function refreshAPMNetworkConfigs(config: InstabugConfig, forceRefreshIOS: boole
319279 if ( Platform . OS === 'ios' && forceRefreshIOS ) {
320280 handleIOSNativeInterception ( config ) ;
321281 }
322- _logFlags ( ) ;
323282 setApmNetworkFlagsIfChanged ( {
324283 isNativeInterceptionFeatureEnabled,
325284 hasAPMNetworkPlugin,
@@ -339,10 +298,6 @@ function refreshAPMNetworkConfigs(config: InstabugConfig, forceRefreshIOS: boole
339298function addOnFeatureUpdatedListener ( config : InstabugConfig ) {
340299 emitter . addListener ( NativeEvents . IBG_ON_FEATURES_UPDATED_CALLBACK , ( flags ) => {
341300 const { cpNativeInterceptionEnabled, hasAPMPlugin } = flags ;
342- console . log ( `Andrew: addOnFeatureUpdatedListener ->
343- isNativeInterceptionFeatureEnabled: ${ cpNativeInterceptionEnabled } ,
344- hasAPMNetworkPlugin: ${ hasAPMPlugin } .
345- ` ) ;
346301 isNativeInterceptionFeatureEnabled = cpNativeInterceptionEnabled ;
347302 hasAPMNetworkPlugin = hasAPMPlugin ;
348303 shouldEnableNativeInterception =
0 commit comments