don't allow to create libraries with duplicated names

This commit is contained in:
nik
2015-05-19 16:22:43 +03:00
parent 3688da26bb
commit f5cacc81d9
@@ -102,6 +102,7 @@ public abstract class BaseLibrariesConfigurable extends BaseStructureConfigurabl
@Override
public void checkCanApply() throws ConfigurationException {
super.checkCanApply();
checkForEmptyAndDuplicatedNames("Library", CommonBundle.getErrorTitle(), LibraryConfigurable.class);
for (LibraryConfigurable configurable : getLibraryConfigurables()) {
if (configurable.getDisplayName().isEmpty()) {
((LibraryProjectStructureElement)configurable.getProjectStructureElement()).navigate();