Skip to content

Commit

Permalink
Improve deprecated exception message
Browse files Browse the repository at this point in the history
Update the exception message so that it includes the class name of the
implementation.

See gh-22497
  • Loading branch information
philwebb committed Jul 27, 2020
1 parent 1c22ec9 commit 84bcd0e
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,8 @@ public boolean supportsEventType(Class<? extends ApplicationEvent> eventType) {

@Override
public void onApplicationEvent(ApplicationEvent event) {
throw new IllegalStateException(
"ConfigFileApplicationListener is deprecated and can only be used as an EnvironmentPostProcessor");
throw new IllegalStateException("ConfigFileApplicationListener [" + getClass().getName()
+ "] is deprecated and can only be used as an EnvironmentPostProcessor");
}

@Override
Expand Down

0 comments on commit 84bcd0e

Please sign in to comment.