Skip to content

Allow Event.emit to handle multiple arguments#4408

Merged
jbudz merged 1 commit intoelastic:masterfrom
w33ble:event-args
Jul 10, 2015
Merged

Allow Event.emit to handle multiple arguments#4408
jbudz merged 1 commit intoelastic:masterfrom
w33ble:event-args

Conversation

@w33ble
Copy link
Contributor

@w33ble w33ble commented Jul 9, 2015

Our Event class was only handling a single argument on events, that is:

evented.emit('name', payload);
evented.on('name', function (payload) {})

This PR allows the use of multiple arguments in the emitters and handlers, like so:

evented.emit('name', item1, item2, item3);
evented.on('name', function (item1, item2, item3) {})

@w33ble w33ble assigned spalger and jbudz and unassigned spalger Jul 9, 2015
@spalger
Copy link
Contributor

spalger commented Jul 9, 2015

LGTM

@jbudz
Copy link
Contributor

jbudz commented Jul 10, 2015

👍

jbudz added a commit that referenced this pull request Jul 10, 2015
Allow Event.emit to handle multiple arguments
@jbudz jbudz merged commit 9449f18 into elastic:master Jul 10, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants