aboutsummaryrefslogtreecommitdiff
path: root/Emby.Server.Implementations/Xml/XmlReaderSettingsFactory.cs
blob: 0f4e8af3c60756f1466b0da4fd085bd9c474c64c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
using System.Xml;
using MediaBrowser.Model.Xml;

namespace Emby.Server.Implementations.Xml
{
    public class XmlReaderSettingsFactory : IXmlReaderSettingsFactory
    {
        public XmlReaderSettings Create(bool enableValidation)
        {
            var settings = new XmlReaderSettings();

            if (!enableValidation)
            {
                settings.ValidationType = ValidationType.None;
            }

            return settings;
        }
    }
}