gui/modules/desktop/electron/libs/logger.ts
ABevier 6c3be19da2
Prettier (#522)
* Fix Prettier config
2023-04-28 12:14:44 +08:00

13 lines
306 B
TypeScript

import log from "electron-log";
export const setSentryLogging = (sentry: any) => {
const oldError = log.error;
log.error = (...params: any[]) => {
oldError(params);
sentry.captureException(params[0].message);
};
};
// Export the log object to use it throughout the app
export default log;