Merge pull request #3908 from crobibero/xml-formatter

Use proper mediatypename
This commit is contained in:
Bond-009 2020-08-16 21:15:05 +02:00 committed by GitHub
commit 57cc08691a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,4 +1,5 @@
using System.Text;
using System.Net.Mime;
using System.Text;
using System.Threading.Tasks;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc.Formatters;
@ -15,7 +16,7 @@ namespace Jellyfin.Server.Formatters
/// </summary>
public XmlOutputFormatter()
{
SupportedMediaTypes.Add("text/xml");
SupportedMediaTypes.Add(MediaTypeNames.Text.Xml);
SupportedMediaTypes.Add("text/xml;charset=UTF-8");
SupportedEncodings.Add(Encoding.UTF8);
SupportedEncodings.Add(Encoding.Unicode);