Skip to content

Commit

Permalink
Fixing String building for not found exception
Browse files Browse the repository at this point in the history
  • Loading branch information
cuioss committed Jan 16, 2024
1 parent bbcde41 commit 41f18c3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/main/java/de/cuioss/tools/io/ClassPathLoader.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@

import java.io.IOException;
import java.io.InputStream;
import java.io.Serial;
import java.net.URL;
import java.util.Optional;

Expand All @@ -39,6 +40,7 @@
@ToString
public class ClassPathLoader implements FileLoader {

@Serial
private static final long serialVersionUID = 9140071059594577808L;

private static final CuiLogger log = new CuiLogger(ClassPathLoader.class);
Expand Down Expand Up @@ -103,7 +105,7 @@ public boolean isReadable() {

@Override
public InputStream inputStream() {
checkState(isReadable(), "Resource '{}' is not readable", givenPathName);
checkState(isReadable(), "Resource '%s' is not readable", givenPathName);
try {
return getURL().openStream();
} catch (IOException e) {
Expand Down

0 comments on commit 41f18c3

Please sign in to comment.