Skip to content

Commit 059e658

Browse files
committed
vowel_5 instead of vowel_4
1 parent f70a607 commit 059e658

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

lib/docsplit/text_cleaner.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ class TextCleaner
2929
CONSONANT = /(^y|[bcdfghjklmnpqrstvwxz])/i
3030
VOWEL = /([aeiou]|y$)/i
3131
CONSONANT_5 = /[bcdfghjklmnpqrstvwxyz]{5}/i
32-
VOWEL_4 = /[aeiou]{4}/i
32+
VOWEL_5 = /[aeiou]{5}/i
3333
REPEATED = /(\b\S{1,2}\s+)(\S{1,3}\s+){5,}(\S{1,2}\s+)/
3434
SINGLETONS = /^[AaIi]$/
3535

@@ -73,7 +73,7 @@ def garbage(w)
7373
(w[1...-1].scan(PUNCT).uniq.length >= 3) ||
7474

7575
# Four or more consecutive vowels, or five or more consecutive consonants.
76-
((w =~ VOWEL_4) || (w =~ CONSONANT_5)) ||
76+
((w =~ VOWEL_5) || (w =~ CONSONANT_5)) ||
7777

7878
# Number of uppercase letters greater than lowercase letters, but the word is
7979
# not all uppercase + punctuation.

0 commit comments

Comments
 (0)