Included scoped namespace
This commit is contained in:
		
							parent
							
								
									d4d70ab821
								
							
						
					
					
						commit
						3e769f9972
					
				| @ -1,11 +1,7 @@ | |||||||
| using Microsoft.AspNetCore.Mvc; | namespace WebStatus.Controllers; | ||||||
| using Microsoft.Extensions.Configuration; |  | ||||||
| using System.Linq; |  | ||||||
| 
 | 
 | ||||||
| namespace WebStatus.Controllers | public class HomeController : Controller | ||||||
| { | { | ||||||
|     public class HomeController : Controller |  | ||||||
|     { |  | ||||||
|     private IConfiguration _configuration; |     private IConfiguration _configuration; | ||||||
| 
 | 
 | ||||||
|     public HomeController(IConfiguration configuration) |     public HomeController(IConfiguration configuration) | ||||||
| @ -37,5 +33,4 @@ namespace WebStatus.Controllers | |||||||
|     { |     { | ||||||
|         return View(); |         return View(); | ||||||
|     } |     } | ||||||
|     } |  | ||||||
| } | } | ||||||
|  | |||||||
| @ -1,17 +1,4 @@ | |||||||
| using Microsoft.AspNetCore; | var configuration = GetConfiguration(); | ||||||
| using Microsoft.AspNetCore.Hosting; |  | ||||||
| using Microsoft.Extensions.Configuration; |  | ||||||
| using Serilog; |  | ||||||
| using System; |  | ||||||
| using System.Collections.Generic; |  | ||||||
| using System.IO; |  | ||||||
| using System.Linq; |  | ||||||
| using System.Reflection; |  | ||||||
| using WebStatus; |  | ||||||
| using Azure.Identity; |  | ||||||
| using Azure.Core; |  | ||||||
| 
 |  | ||||||
| var configuration = GetConfiguration(); |  | ||||||
| 
 | 
 | ||||||
| Log.Logger = CreateSerilogLogger(configuration); | Log.Logger = CreateSerilogLogger(configuration); | ||||||
| 
 | 
 | ||||||
| @ -116,7 +103,7 @@ void LogPackagesVersionInfo() | |||||||
|     Log.Logger.ForContext("PackageVersions", string.Join("\n", versionList)).Information("Package versions ({ApplicationContext})", Program.AppName); |     Log.Logger.ForContext("PackageVersions", string.Join("\n", versionList)).Information("Package versions ({ApplicationContext})", Program.AppName); | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| public class Program | public partial class Program | ||||||
| { | { | ||||||
|     private static readonly string _namespace = typeof(Startup).Namespace; |     private static readonly string _namespace = typeof(Startup).Namespace; | ||||||
|     public static readonly string AppName = _namespace; |     public static readonly string AppName = _namespace; | ||||||
|  | |||||||
| @ -1,17 +1,7 @@ | |||||||
| using Microsoft.AspNetCore.Builder; | namespace WebStatus; | ||||||
| using Microsoft.AspNetCore.Diagnostics.HealthChecks; |  | ||||||
| using Microsoft.AspNetCore.Hosting; |  | ||||||
| using Microsoft.AspNetCore.Mvc; |  | ||||||
| using Microsoft.Extensions.Configuration; |  | ||||||
| using Microsoft.Extensions.DependencyInjection; |  | ||||||
| using Microsoft.Extensions.Diagnostics.HealthChecks; |  | ||||||
| using Microsoft.Extensions.Hosting; |  | ||||||
| using Microsoft.Extensions.Logging; |  | ||||||
| 
 | 
 | ||||||
| namespace WebStatus | public class Startup | ||||||
| { | { | ||||||
|     public class Startup |  | ||||||
|     { |  | ||||||
|     public Startup(IConfiguration configuration) |     public Startup(IConfiguration configuration) | ||||||
|     { |     { | ||||||
|         Configuration = configuration; |         Configuration = configuration; | ||||||
| @ -83,5 +73,4 @@ namespace WebStatus | |||||||
|         services.AddApplicationInsightsTelemetry(Configuration); |         services.AddApplicationInsightsTelemetry(Configuration); | ||||||
|         services.AddApplicationInsightsKubernetesEnricher(); |         services.AddApplicationInsightsKubernetesEnricher(); | ||||||
|     } |     } | ||||||
|     } |  | ||||||
| } | } | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user