diff options
Diffstat (limited to 'shared/src')
-rw-r--r-- | shared/src/main/java/com/vaadin/shared/util/SharedUtil.java | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/shared/src/main/java/com/vaadin/shared/util/SharedUtil.java b/shared/src/main/java/com/vaadin/shared/util/SharedUtil.java index 974c45ae02..d1b7cf0b22 100644 --- a/shared/src/main/java/com/vaadin/shared/util/SharedUtil.java +++ b/shared/src/main/java/com/vaadin/shared/util/SharedUtil.java @@ -93,13 +93,10 @@ public class SharedUtil implements Serializable { } else if (!Character.isUpperCase(camelCaseString.charAt(i - 1))) { // Word ends if previous char wasn't upper case return true; - } else if (i + 1 < camelCaseString.length() - && !Character.isUpperCase(camelCaseString.charAt(i + 1))) { - // Word ends if next char isn't upper case - return true; - } else { - return false; } + // Word ends if next char isn't upper case + return i + 1 < camelCaseString.length() + && !Character.isUpperCase(camelCaseString.charAt(i + 1)); } /** |