revert: move the encoding.xml EncoderPreset fix to its own branch
ci/woodpecker/push/ci Pipeline was successful
ci/woodpecker/pr/ci Pipeline was successful

It is an unrelated subsystem and ships as a separate change.
This commit is contained in:
2026-09-12 16:21:47 +10:00
parent 65af2bcbd7
commit 2f9b8888e9
2 changed files with 0 additions and 69 deletions
@@ -1,10 +1,7 @@
#pragma warning disable CA1819 // XML serialization handles collections improperly, so we need to use arrays
#nullable disable
using System;
using System.ComponentModel;
using System.Text.Json.Serialization;
using System.Xml.Serialization;
using MediaBrowser.Model.Entities;
namespace MediaBrowser.Model.Configuration;
@@ -237,24 +234,8 @@ public class EncodingOptions
/// <summary>
/// Gets or sets the encoder preset.
/// </summary>
[XmlIgnore]
public EncoderPreset EncoderPreset { get; set; }
/// <summary>
/// Gets or sets the encoder preset as it is stored in the configuration file. Files written before the preset
/// list was validated can carry an empty element, which has to read back as the default rather than throw and
/// take the rest of the configuration down with it.
/// </summary>
[JsonIgnore]
[XmlElement(nameof(EncoderPreset))]
public string EncoderPresetXml
{
get => EncoderPreset.ToString();
set => EncoderPreset = Enum.TryParse<EncoderPreset>(value, true, out var encoderPreset)
? encoderPreset
: EncoderPreset.auto;
}
/// <summary>
/// Gets or sets a value indicating whether the framerate is doubled when deinterlacing.
/// </summary>