diff --git a/lib/text_sentinel.rb b/lib/text_sentinel.rb index e7c75f64dc8..230791e62df 100644 --- a/lib/text_sentinel.rb +++ b/lib/text_sentinel.rb @@ -53,7 +53,7 @@ class TextSentinel def seems_unpretentious? # Don't allow super long words if there is a word length maximum - @opts[:max_word_length].blank? || (@text.split(/\W/).map(&:size).max <= @opts[:max_word_length]) + @opts[:max_word_length].blank? || @text.split(/\s/).map(&:size).max <= @opts[:max_word_length] end