Remove returns from event handlers
authorKevin Sawicki <kevinsawicki@gmail.com>
Fri, 11 Mar 2016 19:05:48 +0000 (11:05 -0800)
committerKevin Sawicki <kevinsawicki@gmail.com>
Fri, 11 Mar 2016 19:25:56 +0000 (11:25 -0800)
lib/browser/api/browser-window.js

index 7d99c48..7e2a8d3 100644 (file)
@@ -69,29 +69,29 @@ BrowserWindow.prototype._init = function() {
   // Though this hack is only needed on OS X when the app is launched from
   // Finder, we still do it on all platforms in case of other bugs we don't know.
   this.webContents.once('load-url', function() {
-    return this.focus();
+    this.focus();
   });
 
   // Redirect focus/blur event to app instance too.
   this.on('blur', (event) => {
-    return app.emit('browser-window-blur', event, this);
+    app.emit('browser-window-blur', event, this);
   });
   this.on('focus', (event) => {
-    return app.emit('browser-window-focus', event, this);
+    app.emit('browser-window-focus', event, this);
   });
 
   // Evented visibilityState changes
   this.on('show', () => {
-    return this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
+    this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
   });
   this.on('hide', () => {
-    return this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
+    this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
   });
   this.on('minimize', () => {
-    return this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
+    this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
   });
   this.on('restore', () => {
-    return this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
+    this.webContents.send('ATOM_RENDERER_WINDOW_VISIBILITY_CHANGE', this.isVisible(), this.isMinimized());
   });
 
   // Notify the creation of the window.
@@ -99,15 +99,15 @@ BrowserWindow.prototype._init = function() {
 
   // Be compatible with old APIs.
   this.webContents.on('devtools-focused', () => {
-    return this.emit('devtools-focused');
+    this.emit('devtools-focused');
   });
   this.webContents.on('devtools-opened', () => {
-    return this.emit('devtools-opened');
+    this.emit('devtools-opened');
   });
   this.webContents.on('devtools-closed', () => {
-    return this.emit('devtools-closed');
+    this.emit('devtools-closed');
   });
-  return Object.defineProperty(this, 'devToolsWebContents', {
+  Object.defineProperty(this, 'devToolsWebContents', {
     enumerable: true,
     configurable: false,
     get: function() {