diff --git a/CHANGELOG.md b/CHANGELOG.md index d254e5f5..e4c235d5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## Unreleased +## 7.1.1 + +- fix: Preload injection path (#1243) + ## 7.1.0 - feat: Update JavaScript SDKs from [v10.7.0](https://github.com/getsentry/sentry-javascript/releases/tag/10.7.0) to [v10.11.0](https://github.com/getsentry/sentry-javascript/releases/tag/10.11.0) (#1236) diff --git a/src/main/integrations/preload-injection.ts b/src/main/integrations/preload-injection.ts index 226905db..6f13bccf 100644 --- a/src/main/integrations/preload-injection.ts +++ b/src/main/integrations/preload-injection.ts @@ -11,13 +11,13 @@ import { ElectronMainOptionsInternal } from '../sdk.js'; // to ensure we check for that! function getPreloadPath(): string | number | undefined { try { - return require.resolve('../../preload/index.js'); + return require.resolve('../../preload/default.js'); } catch (_) { try { // This could be ESM const currentDir = fileURLToPath(import.meta.url); // Use the CJS preload - return resolve(currentDir, '..', '..', '..', '..', 'preload', 'index.js'); + return resolve(currentDir, '..', '..', '..', '..', 'preload', 'default.js'); } catch (_) { // }