refactor: crashReporterInit (#16729)

This commit is contained in:
Milan Burda 2019-02-05 21:56:44 +01:00 committed by Shelley Vohr
parent c486ab207a
commit 6d674eebb1
6 changed files with 59 additions and 67 deletions

View file

@ -1,11 +1,11 @@
'use strict'
const CrashReporter = require('@electron/internal/common/crash-reporter')
const ipcRenderer = require('@electron/internal/renderer/ipc-renderer-internal')
const ipcRendererUtils = require('@electron/internal/renderer/ipc-renderer-internal-utils')
class CrashReporterRenderer extends CrashReporter {
sendSync (channel, ...args) {
return ipcRenderer.sendSync(channel, ...args)
init (options) {
return ipcRendererUtils.invokeSync('ELECTRON_CRASH_REPORTER_INIT', options)
}
}