Implement crash-reporter.getLastLastCrashReport API on OS X.

This commit is contained in:
Haojian Wu 2015-06-03 09:47:42 +08:00
parent 2396b51cb6
commit 4457edb1d3
6 changed files with 72 additions and 0 deletions

View file

@ -41,6 +41,10 @@ class CrashReporter
start()
getLastCrashReport: ->
if process.platform is 'darwin'
reports = binding._getUploadedReports()
return if reports.length > 0 then reports[0] else null
tmpdir =
if process.platform is 'win32'
os.tmpdir()