public ProjectTemplate @NotNull [] createTemplates(@Nullable String group) {
    // myGroups contains only not-null keys
    if (!CUSTOM_GROUP.equals(group)) {
      return ProjectTemplate.EMPTY_ARRAY;
    }

    List<ProjectTemplate> templates = null;
    URL url = getCustomTemplatesURL();
    try {
      for (String child : UrlUtil.getChildrenRelativePaths(url)) {
        if (child.endsWith(ZIP)) {
          if (templates == null) {
            templates = new SmartList<>();
          }
          templates.add(new LocalArchivedTemplate(new URL(url.toExternalForm() + '/' + child), ClassLoader.getSystemClassLoader()));
        }
      }
    }
    catch (IOException e) {
      LOG.error(e);
    }
    return ContainerUtil.isEmpty(templates) ? ProjectTemplate.EMPTY_ARRAY : templates.toArray(ProjectTemplate.EMPTY_ARRAY);
  }
public ProjectTemplate @NotNull [] createTemplates(@Nullable String group)