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

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


The following commit(s) were added to refs/heads/master by this push:
     new b8b0e7eb Constant already in scope, use final
b8b0e7eb is described below

commit b8b0e7eb1143487a89f7deb0db7b5475d99336e2
Author: Gary Gregory <[email protected]>
AuthorDate: Thu Jul 9 12:38:51 2026 -0400

    Constant already in scope, use final
---
 src/main/java/org/apache/commons/codec/binary/Base58.java     | 6 +++---
 src/main/java/org/apache/commons/codec/binary/BaseNCodec.java | 2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/main/java/org/apache/commons/codec/binary/Base58.java 
b/src/main/java/org/apache/commons/codec/binary/Base58.java
index b7851a39..66f9331c 100644
--- a/src/main/java/org/apache/commons/codec/binary/Base58.java
+++ b/src/main/java/org/apache/commons/codec/binary/Base58.java
@@ -195,19 +195,19 @@ public class Base58 extends BaseNCodec {
         super(builder);
     }
 
-    private void code(final byte[] array, final int offset, final int length, 
final Context context, BiConsumer<byte[], Context> consumer) {
+    private void code(final byte[] array, final int offset, final int length, 
final Context context, final BiConsumer<byte[], Context> consumer) {
         if (context.eof) {
             return;
         }
         if (length < 0) {
             context.eof = true;
-            final byte[] accumulate = context.buffer = context.buffer != null 
? context.buffer : BaseNCodec.EMPTY_BYTE_ARRAY;
+            final byte[] accumulate = context.buffer = context.buffer != null 
? context.buffer : EMPTY_BYTE_ARRAY;
             if (accumulate.length > 0) {
                 consumer.accept(accumulate, context);
             }
             return;
         }
-        final byte[] accumulate = context.buffer = context.buffer != null ? 
context.buffer : BaseNCodec.EMPTY_BYTE_ARRAY;
+        final byte[] accumulate = context.buffer = context.buffer != null ? 
context.buffer : EMPTY_BYTE_ARRAY;
         final byte[] newAccumulated = new byte[accumulate.length + length];
         if (accumulate.length > 0) {
             System.arraycopy(accumulate, 0, newAccumulated, 0, 
accumulate.length);
diff --git a/src/main/java/org/apache/commons/codec/binary/BaseNCodec.java 
b/src/main/java/org/apache/commons/codec/binary/BaseNCodec.java
index 132dd1e6..1096ad45 100644
--- a/src/main/java/org/apache/commons/codec/binary/BaseNCodec.java
+++ b/src/main/java/org/apache/commons/codec/binary/BaseNCodec.java
@@ -426,7 +426,7 @@ public abstract class BaseNCodec implements BinaryEncoder, 
BinaryDecoder {
         return array == null ? 0 : array.length;
     }
 
-    private static int gte0(int value) {
+    private static int gte0(final int value) {
         if (value < 0) {
             throw new IllegalArgumentException("value must be greater than or 
equal to 0.");
         }

Reply via email to