Commit 1250b5e9 authored by Guillaume Lebigot's avatar Guillaume Lebigot

Test with window export

parent 6ed22bbb
......@@ -96,11 +96,12 @@ if (existsSync(resolve(originalAppPath, 'database.json')) && !existsSync(resolve
moveSync(resolve(originalAppPath, 'database.json'), resolve(dataPath, 'database.json'));
export let win: Electron.BrowserWindow;
setState({originalAppPath: originalAppPath, appPath: appPath, dataPath: dataPath, resourcePath: resourcePath});
process.env['NODE_ENV'] = 'production'; // Default
let win: Electron.BrowserWindow;
if(app) {
// Cette méthode sera appelée quand Electron aura fini
import Transport from 'winston-transport';
import {ipcMain} from 'electron';
import {win} from '../index';
export class IPCTransport extends Transport {
constructor(opts: any) {
......@@ -7,7 +7,7 @@ export class IPCTransport extends Transport {
log(info: any, callback: any) {
ipcMain.emit('log', info);
win.webContents.send('log', info);
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment