You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by or...@apache.org on 2023/05/24 15:09:08 UTC

[camel] 03/10: (chores) camel-util: avoid unnecessary type conversion

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

orpiske pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git

commit cb7093f009cee47066b850e5bc46405613d4bd59
Author: Otavio Rodolfo Piske <an...@gmail.com>
AuthorDate: Wed May 24 14:21:36 2023 +0200

    (chores) camel-util: avoid unnecessary type conversion
---
 core/camel-util/src/main/java/org/apache/camel/util/URISupport.java | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/core/camel-util/src/main/java/org/apache/camel/util/URISupport.java b/core/camel-util/src/main/java/org/apache/camel/util/URISupport.java
index 34ab4570322..202d107db9f 100644
--- a/core/camel-util/src/main/java/org/apache/camel/util/URISupport.java
+++ b/core/camel-util/src/main/java/org/apache/camel/util/URISupport.java
@@ -459,14 +459,13 @@ public final class URISupport {
         try {
             StringBuilder rc = new StringBuilder();
             boolean first = true;
-            for (Object o : sortedKeys) {
+            for (String key : sortedKeys) {
                 if (first) {
                     first = false;
                 } else {
                     rc.append("&");
                 }
 
-                String key = (String) o;
                 Object value = options.get(key);
 
                 // the value may be a list since the same key has multiple