private void GetTargetFrameworks(ProjectBuildResult result, Buildalyzer.IAnalyzerResult analyzerResult) { result.TargetFramework = analyzerResult.TargetFramework; var targetFrameworks = analyzerResult.GetProperty(Constants.TargetFrameworks); if (!string.IsNullOrEmpty(targetFrameworks)) { result.TargetFrameworks = targetFrameworks.Split(';').ToList(); } }
private void GetTargetFrameworks(ProjectBuildResult result, Buildalyzer.IAnalyzerResult analyzerResult) { if (analyzerResult != null) { result.TargetFramework = analyzerResult.TargetFramework; var targetFrameworks = analyzerResult.GetProperty(Constants.TargetFrameworks); if (!string.IsNullOrEmpty(targetFrameworks)) { result.TargetFrameworks = targetFrameworks.Split(';').ToList(); } } else { result.TargetFramework = ProjectAnalyzer.ProjectFile.TargetFrameworks.FirstOrDefault(); result.TargetFrameworks = ProjectAnalyzer.ProjectFile.TargetFrameworks.ToList(); } }