Skip to content

Commit

Permalink
Merge pull request #11 from jonasPoehler/master
Browse files Browse the repository at this point in the history
Fix for 'Cannot invoke ... because "classPath" is null.'
  • Loading branch information
LabyStudio committed Apr 21, 2023
2 parents f23bd44 + 2df9bd0 commit 707fbef
Showing 1 changed file with 5 additions and 2 deletions.
Expand Up @@ -89,8 +89,11 @@ public List<ClassFile> compile(Module module, VirtualFile sourceFile, ClassFile
File compiledFile = new File(classObject.getPath());
FileUtil.writeToFile(compiledFile, bytes);

// Add class file to list
classFiles.add(ClassFile.fromClassObject(project, classObject));
// filter out any non-class-objects generated (e. g. files from annotation processing)
if (classObject.getClassName() != null) {
// Add class file to list
classFiles.add(ClassFile.fromClassObject(project, classObject));
}
}
return classFiles;
}
Expand Down

0 comments on commit 707fbef

Please sign in to comment.