Fix unhelpful error message when event can not be fired.