VirtualFile (Project project, @Nullable Module module) { if (module == null) { return project.getBaseDir(); } else { VirtualFile moduleFile = module.getModuleFile(); assert moduleFile != null; return moduleFile.getParent(); } }