Remove duplicate code

I found some code duplication listed on https://codeclimate.com/github/bbatsov/rubocop/issues/categories/duplication that was easy to fix. 

This should also fix the code coverage in [text_util.rb](https://coveralls.io/files/401400345). It is being hidden by the duplicate method in `simple_text_formatter.rb`