Skip to content

Commit

Permalink
Merge pull request #15797 from stuartwdouglas/14705
Browse files Browse the repository at this point in the history
Better message if fired event is null
  • Loading branch information
gsmet committed Mar 17, 2021
2 parents b7c9783 + 79396ba commit 2fef55c
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@ class EventImpl<T> implements Event<T> {

@Override
public void fire(T event) {
Objects.requireNonNull(event, "Event cannot be null");
getNotifier(event.getClass()).notify(event, ObserverExceptionHandler.IMMEDIATE_HANDLER, false);
}

Expand Down

0 comments on commit 2fef55c

Please sign in to comment.