Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't add parent packages, only the ones that are actually present #76

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -1663,9 +1663,8 @@ void addPackages(Bundle b)
try
{
content.getEntries().forEach((s) -> {
if (s.length() > 1 && s.endsWith("/") && s.indexOf('-') < 0)
{
String pkg = s.substring(0, s.length() - 1).replace('/', '.');
if (s.endsWith(".class")) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we change this to be if (!s.endswith("/") && s.contains("/")) {

In other words all paths that are not directories (don't end with "/") and are not part of the default package (paths with no "/" at all).

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think that would probably work yes.

String pkg = s.substring(0, s.lastIndexOf('/')).replace('/', '.');
packageToAtomosContent.put(pkg,
(AtomosContentIndexed) atomosContent);
}
Expand Down
Loading