Skip to content

Commit 9b9f720

Browse files
authored
[MNG-8311] empty but existing <localRepository/> in settings.xml (#1801)
Use default when empty as well --- https://issues.apache.org/jira/browse/MNG-8311
1 parent 4e5c89c commit 9b9f720

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

maven-cli/src/main/java/org/apache/maven/cling/invoker/LookupInvoker.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -621,7 +621,7 @@ protected Path localRepositoryPath(C context) {
621621
}
622622
// settings
623623
userDefinedLocalRepo = context.effectiveSettings.getLocalRepository();
624-
if (userDefinedLocalRepo != null) {
624+
if (userDefinedLocalRepo != null && !userDefinedLocalRepo.isEmpty()) {
625625
return context.userResolver.apply(userDefinedLocalRepo);
626626
}
627627
// defaults

0 commit comments

Comments
 (0)