linux: Don't throw error when using autoUpdater
authorCheng Zhao <zcbenz@gmail.com>
Fri, 13 Nov 2015 02:58:10 +0000 (10:58 +0800)
committerCheng Zhao <zcbenz@gmail.com>
Fri, 13 Nov 2015 02:58:10 +0000 (10:58 +0800)
Fix #3194.

atom/browser/api/lib/auto-updater.coffee
atom/browser/api/lib/auto-updater/auto-updater-native.coffee [moved from atom/browser/api/lib/auto-updater/auto-updater-mac.coffee with 100% similarity]
filenames.gypi

index 41b78a0..d5e69e2 100644 (file)
@@ -1,7 +1,5 @@
-switch process.platform
-  when 'win32'
-    module.exports = require './auto-updater/auto-updater-win'
-  when 'darwin'
-    module.exports = require './auto-updater/auto-updater-mac'
+module.exports =
+  if process.platform is 'win32'
+    require './auto-updater/auto-updater-win'
   else
-    throw new Error('auto-updater is not implemented on this platform')
+    require './auto-updater/auto-updater-native'
index de7ee26..658c8e7 100644 (file)
@@ -10,7 +10,7 @@
     'coffee_sources': [
       'atom/browser/api/lib/app.coffee',
       'atom/browser/api/lib/auto-updater.coffee',
-      'atom/browser/api/lib/auto-updater/auto-updater-mac.coffee',
+      'atom/browser/api/lib/auto-updater/auto-updater-native.coffee',
       'atom/browser/api/lib/auto-updater/auto-updater-win.coffee',
       'atom/browser/api/lib/auto-updater/squirrel-update-win.coffee',
       'atom/browser/api/lib/browser-window.coffee',