Check if we are on develop version and don't send reports

This commit is contained in:
ziajka
2018-04-03 15:58:21 +02:00
parent 3db58dfe7c
commit 116b164da2
2 changed files with 21 additions and 5 deletions

View File

@ -1,8 +1,15 @@
const { SentryClient } = require('@sentry/electron');
var fs = require('fs');
const DSN =
'https://cb7b474b2e874afb8e400c47d1452ecc:7876224cbff543d992cb0ac4021962f8@sentry.io/1040940';
SentryClient.create({
dsn: DSN
});
const isDev = () => {
return fs.existsSync('.git');
};
if (!isDev()) {
SentryClient.create({
dsn: DSN
});
}