fix: temporarily disable xml serialization

in it's current state xml endpoints are not supported, as no known good
way to serialize it exists
This commit is contained in:
2026-01-28 05:13:42 +01:00
parent 6a92451776
commit 3486b82879
2 changed files with 5 additions and 5 deletions

View File

@@ -4,6 +4,7 @@ using Microsoft.OpenApi;
using Shadow.Data;
using Shadow.Tools;
using System.Reflection;
using System.Xml;
var builder = WebApplication.CreateBuilder(args);
@@ -17,7 +18,10 @@ builder.Services.AddDbContext<ApplicationDbContext>(options =>
builder.Services.AddControllers(options =>
{
// Add XML serializer
options.OutputFormatters.Add(new XmlSerializerOutputFormatter());
// options.RespectBrowserAcceptHeader = true;
// options.OutputFormatters.Add(new XmlSerializerOutputFormatter(
// new XmlWriterSettings { OmitXmlDeclaration = true }
// ));
}).AddJsonOptions(options =>
{
// Pretty-print JSON

View File

@@ -43,8 +43,4 @@
<PackageReference Include="Swashbuckle.AspNetCore.SwaggerUI" Version="10.0.1" />
</ItemGroup>
<ItemGroup>
<Folder Include="Mapping\" />
</ItemGroup>
</Project>