# File lib/charlock_holmes/string.rb, line 25 def detect_encoding!(hint_enc=nil) if detected = self.detect_encoding(hint_enc) self.force_encoding detected[:encoding] end self end