private Repository GetRepository(string websiteName) { Site site = WebsiteManagementClient.GetSiteWithCache(websiteName); if (site != null) { return(new Repository(site)); } throw new Exception(Resources.RepositoryNotSetup); }
/// <summary> /// Gets a website instance. /// </summary> /// <param name="name">The website name</param> /// <returns>The website instance</returns> public Site GetWebsite(string name) { name = GetWebsiteName(name); Site website = WebsiteManagementClient.GetSiteWithCache(name); if (website == null) { throw new Exception(string.Format(Resources.InvalidWebsite, name)); } return(website); }