warn on duplicate container resource for ee9

Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
This commit is contained in:
Lachlan Roberts 2023-11-17 16:11:10 +11:00
parent e7bac208b3
commit 4b0f45f121
1 changed files with 5 additions and 1 deletions

View File

@ -714,7 +714,11 @@ public class MetaData
public void addContainerResource(Resource jar)
{
_orderedContainerResources.add(jar);
Objects.requireNonNull(jar);
if (!_orderedContainerResources.contains(jar))
_orderedContainerResources.add(jar);
else
LOG.warn("Duplicate Container Resource {}", jar);
}
public void setWebInfClassesResources(List<Resource> dirs)