mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
PY-18205 Fixed: NPE building skeletons
Check if BuildoutFacetConfiguration paths is not null and run forEach only after that
This commit is contained in:
@@ -123,10 +123,13 @@ public class BuildoutFacet extends Facet<BuildoutFacetConfiguration> implements
|
||||
for (Module module : ModuleManager.getInstance(project).getModules()) {
|
||||
final BuildoutFacet buildoutFacet = getInstance(module);
|
||||
if (buildoutFacet != null) {
|
||||
for (String path : buildoutFacet.getConfiguration().getPaths()) {
|
||||
final VirtualFile file = LocalFileSystem.getInstance().refreshAndFindFileByPath(path);
|
||||
if (file != null) {
|
||||
results.add(file);
|
||||
final List<String> paths = buildoutFacet.getConfiguration().getPaths();
|
||||
if (paths != null) {
|
||||
for (String path : paths) {
|
||||
final VirtualFile file = LocalFileSystem.getInstance().refreshAndFindFileByPath(path);
|
||||
if (file != null) {
|
||||
results.add(file);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user