Skip to content

Commit

Permalink
fix word splitting (#11)
Browse files Browse the repository at this point in the history
  • Loading branch information
zawodskoj authored Jun 13, 2024
1 parent 29c424b commit c0929db
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/VahterBanBot/Antispam.fs
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,9 @@ let distillWords (str: string) =
let isCyr = c >= 'а' && c <= 'я' // who cares about Ё
let isDigit = c >= '0' && c <= '9'
let isDollar = c = '$' // useful
let isAnySpace = Char.IsWhiteSpace(c)

isLat || isCyr || isDigit || isDollar
isLat || isCyr || isDigit || isDollar || isAnySpace

let filteredStr = String.filter isCyrLatAlphaChar (str.ToLower())

Expand Down

0 comments on commit c0929db

Please sign in to comment.