Module: Ahoy::Utils
- Defined in:
- lib/ahoy/utils.rb
Class Method Summary collapse
Class Method Details
.ensure_utf8(str) ⇒ Object
3 4 5 |
# File 'lib/ahoy/utils.rb', line 3 def self.ensure_utf8(str) str.encode("UTF-8", "binary", invalid: :replace, undef: :replace, replace: "") if str end |