gui: disable node in default client

This commit is contained in:
jean-emmanuel 2018-02-09 00:05:50 +01:00
parent 6c264f5279
commit 6fd8fc6c66
2 changed files with 5 additions and 2 deletions

View file

@ -17,7 +17,10 @@ module.exports = function(options={}) {
title: options.title || settings.read('appName'),
icon: path.resolve(__dirname + '/logo.png'),
backgroundColor: options.color || bgColor,
type:options.type
type:options.type,
webPreferences: {
nodeIntegration: !!options.node
}
})
window.loadURL(options.address)

View file

@ -68,7 +68,7 @@ if (settings.cli) {
launcher
app.on('ready',function(){
launcher = require('./electron-window')({address:address, shortcuts:false, width:680, height:626, color:'#283143'})
launcher = require('./electron-window')({address:address, shortcuts:false, width:680, height:626, node:true, color:'#283143'})
})
process.stdout.write = (function(write) {