private static IResource FindOrCreateGroup(IResource parentGroup, string name) { IResourceList childGroups = parentGroup.GetLinksTo("RSSFeedGroup", "Parent"); foreach (IResource child in childGroups) { if (child.GetStringProp("Name") == name) { return(child); } } return(RSSPlugin.CreateFeedGroup(parentGroup, name)); }