Promise<Void> (@NotNull Module from, @NotNull Library library, @NotNull DependencyScope scope, boolean exported) { String name = library.getName(); if (name != null && name.startsWith(MavenArtifact.MAVEN_LIB_PREFIX)) { //it would be better to use RepositoryLibraryType for libraries imported from Maven and fetch mavenId from the library properties instead String mavenCoordinates = StringUtil.trimStart(name, MavenArtifact.MAVEN_LIB_PREFIX); return addDependency(Collections.singletonList(from), new MavenId(mavenCoordinates), scope); } return null; }