Browse Source

Remove outdated NativeDetector check for Kotlin reflection

See gh-25179
pull/28631/head
Juergen Hoeller 2 years ago
parent
commit
c4e8ffece1
  1. 5
      spring-core/src/main/java/org/springframework/core/DefaultParameterNameDiscoverer.java

5
spring-core/src/main/java/org/springframework/core/DefaultParameterNameDiscoverer.java

@ -1,5 +1,5 @@ @@ -1,5 +1,5 @@
/*
* Copyright 2002-2021 the original author or authors.
* Copyright 2002-2022 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@ -40,8 +40,7 @@ package org.springframework.core; @@ -40,8 +40,7 @@ package org.springframework.core;
public class DefaultParameterNameDiscoverer extends PrioritizedParameterNameDiscoverer {
public DefaultParameterNameDiscoverer() {
// TODO Remove this conditional inclusion when upgrading to Kotlin 1.5, see https://youtrack.jetbrains.com/issue/KT-44594
if (KotlinDetector.isKotlinReflectPresent() && !NativeDetector.inNativeImage()) {
if (KotlinDetector.isKotlinReflectPresent()) {
addDiscoverer(new KotlinReflectionParameterNameDiscoverer());
}
addDiscoverer(new StandardReflectionParameterNameDiscoverer());

Loading…
Cancel
Save