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

chengzhang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/shardingsphere.git


The following commit(s) were added to refs/heads/master by this push:
     new 955ea40a41f Fix sonar issues of PostgreSQLComClosePacket (#25714)
955ea40a41f is described below

commit 955ea40a41f083529ce2b98cd239a16d984ffe4a
Author: Liang Zhang <[email protected]>
AuthorDate: Tue May 16 23:37:52 2023 +0800

    Fix sonar issues of PostgreSQLComClosePacket (#25714)
    
    * Fix sonar issues of PostgreSQLComClosePacket
    
    * Fix sonar issues of PostgreSQLComClosePacket
---
 .../command/query/extended/close/PostgreSQLComClosePacket.java     | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git 
a/db-protocol/postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/command/query/extended/close/PostgreSQLComClosePacket.java
 
b/db-protocol/postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/command/query/extended/close/PostgreSQLComClosePacket.java
index cc6862e5003..c267f956217 100644
--- 
a/db-protocol/postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/command/query/extended/close/PostgreSQLComClosePacket.java
+++ 
b/db-protocol/postgresql/src/main/java/org/apache/shardingsphere/db/protocol/postgresql/packet/command/query/extended/close/PostgreSQLComClosePacket.java
@@ -53,25 +53,24 @@ public final class PostgreSQLComClosePacket extends 
PostgreSQLCommandPacket {
     }
     
     @RequiredArgsConstructor
-    @Getter
     public enum Type {
         
         PREPARED_STATEMENT('S'),
         
         PORTAL('P');
         
-        private final char type;
+        private final char value;
         
         /**
          * Value of type.
          *
-         * @param type type
+         * @param type type char
          * @return type
          * @throws PostgreSQLProtocolException PostgreSQL protocol exception
          */
         public static Type valueOf(final char type) {
             for (Type each : values()) {
-                if (type == each.type) {
+                if (type == each.value) {
                     return each;
                 }
             }

Reply via email to