Skip to content

Commit 2f7e650

Browse files
committed
Merge pull request #31847 from achhibi
* pr/31847: Upgrade copyright year of changed file Combine conditions for better readability and simplicity Closes gh-31847
2 parents 43c2e51 + 68931a2 commit 2f7e650

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

spring-aop/src/main/java/org/springframework/aop/config/ScopedProxyBeanDefinitionDecorator.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2021 the original author or authors.
2+
* Copyright 2002-2023 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.
@@ -42,10 +42,8 @@ class ScopedProxyBeanDefinitionDecorator implements BeanDefinitionDecorator {
4242
@Override
4343
public BeanDefinitionHolder decorate(Node node, BeanDefinitionHolder definition, ParserContext parserContext) {
4444
boolean proxyTargetClass = true;
45-
if (node instanceof Element ele) {
46-
if (ele.hasAttribute(PROXY_TARGET_CLASS)) {
47-
proxyTargetClass = Boolean.parseBoolean(ele.getAttribute(PROXY_TARGET_CLASS));
48-
}
45+
if (node instanceof Element ele && ele.hasAttribute(PROXY_TARGET_CLASS)) {
46+
proxyTargetClass = Boolean.parseBoolean(ele.getAttribute(PROXY_TARGET_CLASS));
4947
}
5048

5149
// Register the original bean definition as it will be referenced by the scoped proxy

0 commit comments

Comments
 (0)