Skip to content

Commit d91fc8c

Browse files
committed
No log level check unless String concatenation is following
1 parent 6599383 commit d91fc8c

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

spring-aop/src/main/java/org/springframework/aop/framework/ProxyFactoryBean.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2019 the original author or authors.
2+
* Copyright 2002-2020 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -254,7 +254,7 @@ public Object getObject() throws BeansException {
254254
return getSingletonInstance();
255255
}
256256
else {
257-
if (this.targetName == null && logger.isInfoEnabled()) {
257+
if (this.targetName == null) {
258258
logger.info("Using non-singleton proxies with singleton targets is often undesirable. " +
259259
"Enable prototype proxies by setting the 'targetName' property.");
260260
}
@@ -600,8 +600,8 @@ private Advisor namedBeanToAdvisor(Object next) {
600600
// We expected this to be an Advisor or Advice,
601601
// but it wasn't. This is a configuration error.
602602
throw new AopConfigException("Unknown advisor type " + next.getClass() +
603-
"; Can only include Advisor or Advice type beans in interceptorNames chain except for last entry, " +
604-
"which may also be target or TargetSource", ex);
603+
"; can only include Advisor or Advice type beans in interceptorNames chain " +
604+
"except for last entry which may also be target instance or TargetSource", ex);
605605
}
606606
}
607607

0 commit comments

Comments
 (0)