Fix usage of RegexOptions.Compiled

pull/6956/head
cvium 3 years ago
parent 5c3d0b5510
commit 9e665ff520

@ -60,9 +60,9 @@ namespace Emby.Naming.Video
{
var filename = Path.GetFileName(path);
var regex = new Regex(rule.Token, RegexOptions.IgnoreCase | RegexOptions.Compiled);
var isMatch = Regex.IsMatch(filename, rule.Token, RegexOptions.IgnoreCase | RegexOptions.Compiled);
if (regex.IsMatch(filename))
if (isMatch)
{
result.ExtraType = rule.ExtraType;
result.Rule = rule;

Loading…
Cancel
Save