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 2023/08/01 14:53:36 UTC

[commons-dbutils] 01/15: Inline single use variable

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-dbutils.git

commit f7ae3c7534ed52ebf552247bb4858fd4a587e6c2
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Tue Aug 1 09:51:22 2023 -0400

    Inline single use variable
---
 src/main/java/org/apache/commons/dbutils/OutParameter.java | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/src/main/java/org/apache/commons/dbutils/OutParameter.java b/src/main/java/org/apache/commons/dbutils/OutParameter.java
index 127c20a..0489452 100644
--- a/src/main/java/org/apache/commons/dbutils/OutParameter.java
+++ b/src/main/java/org/apache/commons/dbutils/OutParameter.java
@@ -120,8 +120,7 @@ public class OutParameter<T> {
      * statement.
      */
     void setValue(final CallableStatement stmt, final int index) throws SQLException {
-        final Object object = stmt.getObject(index);
-        value = javaType.cast(object);
+        value = javaType.cast(stmt.getObject(index));
     }
 
     /**