diff --git a/lib/gitlabhq/encode.rb b/lib/gitlabhq/encode.rb index 780d839f..1a81acce 100644 --- a/lib/gitlabhq/encode.rb +++ b/lib/gitlabhq/encode.rb @@ -12,7 +12,7 @@ module Gitlabhq # It's better to default to UTF-8 as sometimes it's wrongly detected as another charset if detect[:encoding] && detect[:confidence] == 100 - CharlockHolmes::Converter.convert(message, encoding, 'UTF-8') + CharlockHolmes::Converter.convert(message, detect[:encoding], 'UTF-8') else message end.force_encoding("utf-8")