I am currently using Laravel 4.2.
When I fire an Event sending the payload as array, listener retrieves the payload with it only being the first item in the associative array.
Firing the event:
$data = array('user' => $user, 'password_clear' => $pass);
Event::fire('user.created', $data);
Listening like this:
Event::listen('user.created', function($data) {
dd($data);
}
Dumps the following:
object(User)#809 (20) {
...
}
While I would have expected an array. Am I missing something?
Thanks, Federico