@newrelic/browser-agent 1.303.0-rc.7 → 1.303.0-rc.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,7 +17,7 @@ exports.VERSION = exports.RRWEB_VERSION = exports.RRWEB_PACKAGE_NAME = exports.D
17
17
  /**
18
18
  * Exposes the version of the agent
19
19
  */
20
- const VERSION = exports.VERSION = "1.303.0-rc.7";
20
+ const VERSION = exports.VERSION = "1.303.0-rc.8";
21
21
 
22
22
  /**
23
23
  * Exposes the build type of the agent
@@ -17,7 +17,7 @@ exports.VERSION = exports.RRWEB_VERSION = exports.RRWEB_PACKAGE_NAME = exports.D
17
17
  /**
18
18
  * Exposes the version of the agent
19
19
  */
20
- const VERSION = exports.VERSION = "1.303.0-rc.7";
20
+ const VERSION = exports.VERSION = "1.303.0-rc.8";
21
21
 
22
22
  /**
23
23
  * Exposes the build type of the agent
@@ -20,9 +20,11 @@ const checked = new Map();
20
20
  function isNative(...fns) {
21
21
  return fns.every(fn => {
22
22
  if (checked.has(fn)) return checked.get(fn);
23
- const isNative = typeof fn === 'function' && fn.toString().includes('[native code]');
24
- if (!isNative) {
25
- (0, _console.warn)(64, fn?.name || fn?.toString());
23
+ const fnString = typeof fn === 'function' ? fn.toString() : '';
24
+ const isNative = fnString.includes('[native code]');
25
+ const isNr = fnString.includes('nrWrapper');
26
+ if (!isNative && !isNr) {
27
+ (0, _console.warn)(64, fn?.name || fnString);
26
28
  }
27
29
  checked.set(fn, isNative);
28
30
  return isNative;
@@ -11,7 +11,7 @@
11
11
  /**
12
12
  * Exposes the version of the agent
13
13
  */
14
- export const VERSION = "1.303.0-rc.7";
14
+ export const VERSION = "1.303.0-rc.8";
15
15
 
16
16
  /**
17
17
  * Exposes the build type of the agent
@@ -11,7 +11,7 @@
11
11
  /**
12
12
  * Exposes the version of the agent
13
13
  */
14
- export const VERSION = "1.303.0-rc.7";
14
+ export const VERSION = "1.303.0-rc.8";
15
15
 
16
16
  /**
17
17
  * Exposes the build type of the agent
@@ -13,9 +13,11 @@ const checked = new Map();
13
13
  export function isNative(...fns) {
14
14
  return fns.every(fn => {
15
15
  if (checked.has(fn)) return checked.get(fn);
16
- const isNative = typeof fn === 'function' && fn.toString().includes('[native code]');
17
- if (!isNative) {
18
- warn(64, fn?.name || fn?.toString());
16
+ const fnString = typeof fn === 'function' ? fn.toString() : '';
17
+ const isNative = fnString.includes('[native code]');
18
+ const isNr = fnString.includes('nrWrapper');
19
+ if (!isNative && !isNr) {
20
+ warn(64, fn?.name || fnString);
19
21
  }
20
22
  checked.set(fn, isNative);
21
23
  return isNative;
@@ -1 +1 @@
1
- {"version":3,"file":"monkey-patched.d.ts","sourceRoot":"","sources":["../../../../src/common/util/monkey-patched.js"],"names":[],"mappings":"AAQA;;;;GAIG;AACH,iCAHW,UAAW,GACT,OAAO,CAYnB"}
1
+ {"version":3,"file":"monkey-patched.d.ts","sourceRoot":"","sources":["../../../../src/common/util/monkey-patched.js"],"names":[],"mappings":"AAQA;;;;GAIG;AACH,iCAHW,UAAW,GACT,OAAO,CAcnB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@newrelic/browser-agent",
3
- "version": "1.303.0-rc.7",
3
+ "version": "1.303.0-rc.8",
4
4
  "private": false,
5
5
  "author": "New Relic Browser Agent Team <browser-agent@newrelic.com>",
6
6
  "description": "New Relic Browser Agent",
@@ -14,9 +14,11 @@ const checked = new Map()
14
14
  export function isNative (...fns) {
15
15
  return fns.every(fn => {
16
16
  if (checked.has(fn)) return checked.get(fn)
17
- const isNative = typeof fn === 'function' && fn.toString().includes('[native code]')
18
- if (!isNative) {
19
- warn(64, fn?.name || fn?.toString())
17
+ const fnString = typeof fn === 'function' ? fn.toString() : ''
18
+ const isNative = fnString.includes('[native code]')
19
+ const isNr = fnString.includes('nrWrapper')
20
+ if (!isNative && !isNr) {
21
+ warn(64, fn?.name || fnString)
20
22
  }
21
23
  checked.set(fn, isNative)
22
24
  return isNative