You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

functions.native.js 611B

123456789101112131415161718192021
  1. // @flow
  2. import { NativeModules } from 'react-native';
  3. export * from './functions.any';
  4. /**
  5. * Removes all analytics related options from the given configuration, in case of a libre build.
  6. *
  7. * @param {*} config - The configuration which needs to be cleaned up.
  8. * @returns {void}
  9. */
  10. export function _cleanupConfig(config: Object) {
  11. config.analytics.scriptURLs = [];
  12. if (NativeModules.AppInfo.LIBRE_BUILD) {
  13. delete config.analytics.amplitudeAPPKey;
  14. delete config.analytics.googleAnalyticsTrackingId;
  15. delete config.callStatsID;
  16. delete config.callStatsSecret;
  17. }
  18. }