Commit acfb136b authored by Jesper Öqvist's avatar Jesper Öqvist
Browse files

Code cleanup

parent 2e69ee25
......@@ -158,15 +158,15 @@ aspect PathPart {
String name = packageName.substring(index == -1 ? 0 : index+1);
String folderName = packageName.replace('.', File.separatorChar);
File pkgFolder = new File(folder, folderName);
Collection<String> c = Collections.emptyList();
Collection<String> fileSet = Collections.emptyList();
try {
File canonical = pkgFolder.getCanonicalFile();
if (canonical.isDirectory() && canonical.getName().equals(name)) {
String[] files = pkgFolder.list();
if (files.length > 0) {
c = new HashSet<String>();
fileSet = new HashSet<String>();
for (String file: files) {
c.add(file);
fileSet.add(file);
}
}
}
......@@ -176,7 +176,7 @@ aspect PathPart {
// the empty list in the packageMap, indicating that the package
// does not exist
}
packageMap.put(packageName, c);
packageMap.put(packageName, fileSet);
}
return packageMap.get(packageName);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment