public async Task <ActionResult <AltinnStudioSettings> > Get(string org, string repository) { var developer = AuthenticationHelper.GetDeveloperUserName(HttpContext); AltinnStudioSettings settings; try { var altinnGitRepository = _altinnGitRepositoryFactory.GetAltinnGitRepository(org, repository, developer); settings = await altinnGitRepository.GetAltinnStudioSettings(); } catch (DirectoryNotFoundException) { return(NotFound(new ProblemDetails() { Title = "Not found", Detail = $"Could not find repository {org}/{repository} for user {developer}", Status = (int)HttpStatusCode.NotFound })); } return(Ok(settings)); }
/// <inheritdoc/> public IList <AltinnCoreFile> GetSchemaFiles(string org, string repository, string developer) { var altinnGitRepository = _altinnGitRepositoryFactory.GetAltinnGitRepository(org, repository, developer); return(altinnGitRepository.GetSchemaFiles()); }