Fix bug where directories wrongly adopted resources as their children.
This commit is contained in:
parent
6c44c5fa66
commit
95dd5feb63
1 changed files with 5 additions and 1 deletions
|
@ -104,10 +104,14 @@ public final class ZipRepository extends AbstractRepository {
|
|||
String eName = entry.getName();
|
||||
|
||||
if (!eName.regionMatches(0, entryPath, 0, entryPath.length())) {
|
||||
// not a child of ours
|
||||
// names don't match - not a child of ours
|
||||
continue;
|
||||
}
|
||||
String[] entrypath = StringUtils.split(eName, "/");
|
||||
if (depth > 0 && !shortName.equals(entrypath[depth-1])) {
|
||||
// catch case where our name is Foo and other's is FooBar
|
||||
continue;
|
||||
}
|
||||
|
||||
// create new repositories and resources for all entries with a
|
||||
// path depth of this.depth + 1
|
||||
|
|
Loading…
Add table
Reference in a new issue