Skip to content

Commit

Permalink
fix: Use replace for non-regex (#1100)
Browse files Browse the repository at this point in the history
  • Loading branch information
dwalluck authored Jan 30, 2025
1 parent c07c820 commit 485de5d
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,8 @@ private void validateClientConfiguration() {
for (String prop : Set.of("bucket.region", "bucket.name", "aws.access.key.id", "aws.secret.access.key")) {
Optional<String> valueOpt = ConfigProvider.getConfig().getOptionalValue(prop, String.class);

if (!valueOpt.isPresent()) {
missingConfig.add(prop.toUpperCase().replaceAll("\\.", "_"));
if (valueOpt.isEmpty()) {
missingConfig.add(prop.toUpperCase().replace('.', '_'));
}
}

Expand Down Expand Up @@ -205,7 +205,7 @@ public List<String> logFileNames(String generationRequestId) {
log.debug("Found: '{}'", object.key());

if (object.key().contains("/logs/")) {
paths.add(object.key().replaceAll(generationRequestId + "/", ""));
paths.add(object.key().replace(generationRequestId + "/", ""));
}
}

Expand Down

0 comments on commit 485de5d

Please sign in to comment.