Skip to content
This repository was archived by the owner on Jan 4, 2019. It is now read-only.

Commit f46584a

Browse files
committed
Fix renderer IPC failing
This is failing a bunch of automated tests and general functionality. Bug was introduced here: 96b2f08#diff-6d7213223d17eee94ce8a64e16ead954L29 The assignment was shortcircuited with `arguments[1] &&` before. Fix brave/browser-laptop#6151 Auditors: @bridiver
1 parent 443df24 commit f46584a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

atom/common/api/resources/ipc_utils.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,9 @@ if (!ipcRenderer) {
2525
}
2626

2727
ipcRenderer.emit = function () {
28-
arguments[1].sender = ipcRenderer
28+
if (arguments[1]) {
29+
arguments[1].sender = ipcRenderer
30+
}
2931
return $Function.apply(EventEmitter.prototype.emit, ipcRenderer, arguments)
3032
}
3133
atom.v8.setHiddenValue('ipc', ipcRenderer)

0 commit comments

Comments
 (0)