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


The following commit(s) were added to refs/heads/master by this push:
     new effbb124 Reuse IllegalArgumentExceptions
effbb124 is described below

commit effbb124ff0e37c04406c4c77c4bc12e29fcb33f
Author: Gary Gregory <garydgreg...@gmail.com>
AuthorDate: Fri Apr 5 12:05:49 2024 -0400

    Reuse IllegalArgumentExceptions
---
 .../java/org/apache/commons/text/lookup/AbstractPathFencedLookup.java   | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git 
a/src/main/java/org/apache/commons/text/lookup/AbstractPathFencedLookup.java 
b/src/main/java/org/apache/commons/text/lookup/AbstractPathFencedLookup.java
index e8bce89e..1bc18554 100644
--- a/src/main/java/org/apache/commons/text/lookup/AbstractPathFencedLookup.java
+++ b/src/main/java/org/apache/commons/text/lookup/AbstractPathFencedLookup.java
@@ -60,7 +60,7 @@ abstract class AbstractPathFencedLookup extends 
AbstractStringLookup {
         if (first.isPresent()) {
             return path;
         }
-        throw new IllegalArgumentException(String.format("[%s] -> [%s] not in 
%s", fileName, pathAbs, fences));
+        throw IllegalArgumentExceptions.format("[%s] -> [%s] not in %s", 
fileName, pathAbs, fences);
     }
 
 }

Reply via email to