public async Task <List <FileAnalysisResult> > AnalyzeMultipart([FromForm] AnalyzeFilesMultipleResource data)
        {
            var repoSource = new UploadedRepo();
            await repoSource.ReadUploadedFiles(data.code);

            var repoAnalyzer = new RepoAnalyzer(repoSource);

            repoAnalyzer.AnalyzeRepo();
            UpdateStats(repoAnalyzer.AnalysisResult);
            return(repoAnalyzer.AnalysisResult);
        }
        public async Task <List <FileAnalysisResult> > AnalyzePublicRepo([FromBody] AnalyzeRepoResource data)
        {
            var repoSource = new GitHubRepoTree(data.username, data.reponame);
            await repoSource.FetchData();

            // Using dependency injection - giving RepoAnalyzer a preconfigured repo source
            var repoAnalyzer = new RepoAnalyzer(repoSource);

            repoAnalyzer.AnalyzeRepo();
            UpdateStats(repoAnalyzer.AnalysisResult);
            return(repoAnalyzer.AnalysisResult);
        }