Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
dsn: 'https://27ff620b68bf4da39b40f5d491e16fd8@sentry.io/1779992',
});
Sentry.configureScope(scope => {
scope.setUser({ id: this._getUserId() });
if (this._clientInfo) {
scope.setTags({
OS: String(this._clientInfo[1]),
'Node Version': String(this._clientInfo[2]),
'CPU Count': String(this._clientInfo[3]),
RAM: String(this._clientInfo[4]),
'CLI Version': String(this._clientInfo[5]),
});
}
});
Sentry.captureException(error);
await Sentry.flush();
}
async flush() {
await Sentry.flush();
}
}
async function captureError(message) {
try {
sentry.captureMessage(message, 'error');
await sentry.flush();
} catch (err) {
/** ignore errors*/
return Promise.resolve();
}
}
async function captureException(error) {
try {
sentry.captureException(error);
await sentry.flush();
} catch (err) {
/** ignore errors*/
return Promise.resolve();
}
}