Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/fix/sentry-init-main-process' in…
Browse files Browse the repository at this point in the history
…to fix/prod-fixes
  • Loading branch information
danutzcodrescu committed Apr 6, 2020
2 parents 5d641ed + 38ba506 commit 131c289
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 6 deletions.
2 changes: 1 addition & 1 deletion src/backend/server.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ import { OfferResolver } from './resolvers/offers.resolver';
import { ProfileResolver } from './resolvers/profile.resolver';
import { ServiceResolver } from './resolvers/service.resolver';
import { VatRuleResolver } from './resolvers/vatRules.resolver';
import { init } from '@sentry/electron';
import { init } from '@sentry/electron/dist/main';
import { SENTRY_DSN } from './constants';

if (process.env.NODE_ENV === 'production') {
Expand Down
7 changes: 3 additions & 4 deletions src/main/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@ import * as url from 'url';
import { checkForUpdates } from './autoupdater';
import { exportData } from './export';
import { createInvoice, openInvoice } from './invoices';
import { init } from '@sentry/electron';
import { init } from '@sentry/electron/dist/main';
import { SENTRY_DSN } from '../backend/constants';
import { setMenu } from './menu';

let win: BrowserWindow | null;
let serverProcess: ChildProcess;
if (process.env.NODE_ENV === 'production') {
init({
dsn: SENTRY_DSN,
Expand All @@ -18,9 +20,6 @@ if (process.env.NODE_ENV === 'production') {
});
}

let win: BrowserWindow | null;
let serverProcess: ChildProcess;

const installExtensions = async () => {
// eslint-disable-next-line @typescript-eslint/no-var-requires
const installer = require('electron-devtools-installer');
Expand Down
2 changes: 1 addition & 1 deletion src/renderer/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import * as React from 'react';
import { render } from 'react-dom';
import 'typeface-roboto';
import Application from './components/Application';
import { init } from '@sentry/electron';
import { init } from '@sentry/electron/dist/renderer';
import { remote } from 'electron';
import { SENTRY_DSN } from '../backend/constants';

Expand Down

0 comments on commit 131c289

Please sign in to comment.