mirror of
https://github.com/spring-projects/spring-framework.git
synced 2026-09-21 05:09:13 +00:00
fixed ApplicationContext event processing for repeated invocations to non-singleton listener beans (SPR-7563)
git-svn-id: https://src.springframework.org/svn/spring-framework/trunk@3705 50f2f4bb-b051-0410-bef5-90022cba6387
This commit is contained in:
+1
-1
@@ -238,7 +238,7 @@ public abstract class AbstractApplicationEventMulticaster implements Application
|
||||
BeanFactory beanFactory = getBeanFactory();
|
||||
for (String listenerBeanName : this.applicationListenerBeans) {
|
||||
ApplicationListener listener = beanFactory.getBean(listenerBeanName, ApplicationListener.class);
|
||||
if (!this.preFiltered && !allListeners.contains(listener)) {
|
||||
if (this.preFiltered || !allListeners.contains(listener)) {
|
||||
allListeners.add(listener);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user