Can I use multiple `once` to register the same event?
Closed this issue · 2 comments
haifengkao commented
Suppose I have the following code:
electron_1.app.once('open-file', function (e, p) {
process.argv.push(p);
e.preventDefault();
});
electron_1.app.once('open-file', function (e, p) {
// log the event
console.log('open ' + p);
e.preventDefault();
});
Only one of the events will be received. Is it the expected behavior?
haifengkao commented
Opps. Electron's once
function is not fbemitter's once
function.
Sorry.
kyldvs commented
No worries :)