update deprecation warning

This commit is contained in:
Shelley Vohr 2017-11-01 22:23:33 -04:00
parent 3af83f1c97
commit 24acd74d15
No known key found for this signature in database
GPG key ID: F13993A75599653C
3 changed files with 8 additions and 6 deletions

View file

@ -4,7 +4,7 @@ const {spawn} = require('child_process')
const os = require('os')
const path = require('path')
const electron = require('electron')
const {app} = process.type === 'browser' ? electron : electron.remote
const {app, deprecate} = process.type === 'browser' ? electron : electron.remote
const binding = process.atomBinding('crash_reporter')
class CrashReporter {
@ -104,8 +104,10 @@ class CrashReporter {
}
}
// TODO(2.0) Deprecate
// TODO(2.0) Remove
setExtraParameter (key, value) {
deprecate.warn('crashReporter.setExtraParameter',
'crashReporter.addExtraParameter or crashReporter.removeExtraParameter')
binding.setExtraParameter(key, value)
}