@posthog/core 1.24.3 → 1.24.4

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.
@@ -106,7 +106,7 @@ function isErrorEvent(event) {
106
106
  return isBuiltin(event, 'ErrorEvent');
107
107
  }
108
108
  function isEvent(candidate) {
109
- return !isUndefined(Event) && isInstanceOf(candidate, Event);
109
+ return 'undefined' != typeof Event && isInstanceOf(candidate, Event);
110
110
  }
111
111
  function isPlainObject(candidate) {
112
112
  return isBuiltin(candidate, 'Object');
@@ -51,7 +51,7 @@ function isErrorEvent(event) {
51
51
  return isBuiltin(event, 'ErrorEvent');
52
52
  }
53
53
  function isEvent(candidate) {
54
- return !isUndefined(Event) && isInstanceOf(candidate, Event);
54
+ return 'undefined' != typeof Event && isInstanceOf(candidate, Event);
55
55
  }
56
56
  function isPlainObject(candidate) {
57
57
  return isBuiltin(candidate, 'Object');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@posthog/core",
3
- "version": "1.24.3",
3
+ "version": "1.24.4",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "module": "dist/index.mjs",
@@ -119,7 +119,7 @@ export function isErrorEvent(event: unknown): boolean {
119
119
  }
120
120
 
121
121
  export function isEvent(candidate: unknown): candidate is Event {
122
- return !isUndefined(Event) && isInstanceOf(candidate, Event)
122
+ return typeof Event !== 'undefined' && isInstanceOf(candidate, Event)
123
123
  }
124
124
 
125
125
  export function isPlainObject(candidate: unknown): candidate is Record<string, unknown> {