You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2025/08/11 18:41:46 UTC

(commons-beanutils) branch master updated: Simplify `FluentPropertyBeanIntrospector#propertyName` (#363)

This is an automated email from the ASF dual-hosted git repository.

ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-beanutils.git


The following commit(s) were added to refs/heads/master by this push:
     new 9b75da08 Simplify `FluentPropertyBeanIntrospector#propertyName` (#363)
9b75da08 is described below

commit 9b75da083f07e8e8fe0bbeaff2be330006282c30
Author: Basil Crow <me...@basilcrow.com>
AuthorDate: Mon Aug 11 11:41:40 2025 -0700

    Simplify `FluentPropertyBeanIntrospector#propertyName` (#363)
---
 .../org/apache/commons/beanutils2/FluentPropertyBeanIntrospector.java  | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/main/java/org/apache/commons/beanutils2/FluentPropertyBeanIntrospector.java b/src/main/java/org/apache/commons/beanutils2/FluentPropertyBeanIntrospector.java
index 2783339b..02a38110 100644
--- a/src/main/java/org/apache/commons/beanutils2/FluentPropertyBeanIntrospector.java
+++ b/src/main/java/org/apache/commons/beanutils2/FluentPropertyBeanIntrospector.java
@@ -22,7 +22,6 @@ import java.beans.PropertyDescriptor;
 import java.lang.reflect.Method;
 import java.util.Objects;
 
-import org.apache.commons.lang3.StringUtils;
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
 
@@ -159,6 +158,6 @@ public class FluentPropertyBeanIntrospector implements BeanIntrospector {
      */
     private String propertyName(final Method m) {
         final String methodName = m.getName().substring(getWriteMethodPrefix().length());
-        return methodName.length() > 1 ? Introspector.decapitalize(methodName) : StringUtils.toRootLowerCase(methodName);
+        return Introspector.decapitalize(methodName);
     }
 }