fix spec and docs

This commit is contained in:
deepak1556 2016-06-09 10:38:45 +05:30
parent b91217f29e
commit 4749e18fc0
4 changed files with 18 additions and 24 deletions

View file

@ -1,4 +1,4 @@
const {app, ipcMain, protocol, webContents, BrowserWindow} = require('electron')
const {app, ipcMain, session, webContents, BrowserWindow} = require('electron')
const {getAllWebContents} = process.atomBinding('web_contents')
const renderProcessPreferences = process.atomBinding('render_process_preferences').forAllBrowserWindow()
@ -280,8 +280,8 @@ app.once('ready', function () {
}
})
}
process.on('session-created', function (session) {
session.protocol.registerBufferProtocol('chrome-extension', chromeExtensionHandler, function (error) {
session.on('session-created', function (ses) {
ses.protocol.registerBufferProtocol('chrome-extension', chromeExtensionHandler, function (error) {
if (error) {
console.error(`Unable to register chrome-extension protocol: ${error}`)
}