List<File> (@Nullable Project project, @Nullable String rootProjectPath) { if (project == null) return null; if (rootProjectPath == null) { for (Module module : ModuleManager.getInstance(project).getModules()) { rootProjectPath = ExternalSystemModulePropertyManager.getInstance(module).getRootProjectPath(); List<File> result = findGradleSdkClasspath(project, rootProjectPath); if (!result.isEmpty()) return result; } } else { return findGradleSdkClasspath(project, rootProjectPath); } return null; }