From 7e0b5d26a32a11af548128d33ca52721bf106b11 Mon Sep 17 00:00:00 2001 From: Adam Driscoll Date: Fri, 25 Oct 2019 07:44:34 -0600 Subject: [PATCH] Fixes #1284 --- src/UniversalDashboard/Server/ServerStartup.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/UniversalDashboard/Server/ServerStartup.cs b/src/UniversalDashboard/Server/ServerStartup.cs index 37921f15..6a61e4f3 100644 --- a/src/UniversalDashboard/Server/ServerStartup.cs +++ b/src/UniversalDashboard/Server/ServerStartup.cs @@ -111,6 +111,10 @@ public void Configure(IApplicationBuilder app, Microsoft.AspNetCore.Hosting.IHos if (asset != null) { var response = context.HttpContext.Response; + if (provider.TryGetContentType(asset, out string mimeType)) + { + response.ContentType = mimeType; + } response.StatusCode = 200; var file = File.ReadAllBytes(asset); await response.Body.WriteAsync(file, 0, file.Length);