Skip to content

Commit

Permalink
fix: regex
Browse files Browse the repository at this point in the history
  • Loading branch information
iPromKnight committed Nov 17, 2024
1 parent 9f5f5a2 commit ebd58e1
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/Zilean.Shared/Features/Utilities/Parsing.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,11 @@ public static partial class Parsing
[GeneratedRegex(@"^(?:tt)?(\d{1,8})$", RegexOptions.Compiled)]
private static partial Regex ImdbIdRegex();

[GeneratedRegex(@"\s+")]
[GeneratedRegex(@"\s+", RegexOptions.Compiled)]
private static partial Regex SpaceRegex();
[GeneratedRegex(@"(?i)\b(?:a|the|and|of|in|on|with|to|for|by|is|it)\b", RegexOptions.None, "en-GB")]
[GeneratedRegex(@"(?i)\b(?:a|the|and|of|in|on|with|to|for|by|is|it)\b", RegexOptions.Compiled)]
private static partial Regex StopWordRegex();
[GeneratedRegex(@"\s{2,}")]
[GeneratedRegex(@"\s{2,}", RegexOptions.Compiled)]
private static partial Regex SpaceRemovalRegex();

public static string NormalizeSpace(string s) => s?.Trim() ?? string.Empty;
Expand Down

0 comments on commit ebd58e1

Please sign in to comment.