Commit bbb93de1 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Merge pull request #704 from tader/workaround-charlock-holmes

Rescue from CharlockHolmes failures.
parents af99e4af b53df221
...@@ -3,7 +3,7 @@ module Gitlabhq ...@@ -3,7 +3,7 @@ module Gitlabhq
extend self extend self
def utf8 message def utf8 message
hash = CharlockHolmes::EncodingDetector.detect(message) hash = CharlockHolmes::EncodingDetector.detect(message) rescue {}
if hash[:encoding] if hash[:encoding]
CharlockHolmes::Converter.convert(message, hash[:encoding], 'UTF-8') CharlockHolmes::Converter.convert(message, hash[:encoding], 'UTF-8')
else else
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment