feat: promisify webContents.savePage() (#16742)

* feat: promisify webContents.savePage()

* no need to make compatible w callbacks, we're breaking it

* fix promise resolve type

* address feedback from review

* fix promise return text

* update smoke test
This commit is contained in:
Shelley Vohr 2019-02-14 09:03:28 -08:00 committed by GitHub
parent 6e7dca9082
commit de27911661
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 35 additions and 40 deletions

View file

@ -344,6 +344,7 @@ WebContents.prototype.loadFile = function (filePath, options = {}) {
WebContents.prototype.capturePage = deprecate.promisify(WebContents.prototype.capturePage)
WebContents.prototype.printToPDF = deprecate.promisify(WebContents.prototype.printToPDF)
WebContents.prototype.savePage = deprecate.promisify(WebContents.prototype.savePage)
const addReplyToEvent = (event) => {
event.reply = (...args) => {