feat: promisify netLog.stopLogging (#16862)

This commit is contained in:
Milan Burda 2019-02-19 11:48:27 +01:00 committed by Alexey Kuzmin
parent 3b74837020
commit 7e7abc28f5
9 changed files with 78 additions and 35 deletions

View file

@ -2,7 +2,7 @@
const { EventEmitter } = require('events')
const { app, deprecate } = require('electron')
const { fromPartition, Session, Cookies, Protocol } = process.atomBinding('session')
const { fromPartition, Session, Cookies, NetLog, Protocol } = process.atomBinding('session')
// Public API.
Object.defineProperties(exports, {
@ -28,4 +28,6 @@ Cookies.prototype.get = deprecate.promisify(Cookies.prototype.get)
Cookies.prototype.remove = deprecate.promisify(Cookies.prototype.remove)
Cookies.prototype.set = deprecate.promisify(Cookies.prototype.set)
NetLog.prototype.stopLogging = deprecate.promisify(NetLog.prototype.stopLogging)
Protocol.prototype.isProtocolHandled = deprecate.promisify(Protocol.prototype.isProtocolHandled)