boolean (String inputString) { inputString = inputString.trim(); if (myName2FavoritesRoots.containsKey(inputString) || getProviders().containsKey(inputString)) { Messages.showErrorDialog(project, IdeBundle.message("error.favorites.list.already.exists", inputString.trim()), IdeBundle.message("title.unable.to.add.favorites.list")); return false; } return !inputString.isEmpty(); }