diff --git a/lib/redmine_git_hosting/hooks/display_repository_readme.rb b/lib/redmine_git_hosting/hooks/display_repository_readme.rb index 59df2da8aa9..6c36cbe5d0e 100644 --- a/lib/redmine_git_hosting/hooks/display_repository_readme.rb +++ b/lib/redmine_git_hosting/hooks/display_repository_readme.rb @@ -55,7 +55,7 @@ def find_readme_file(repository, path, rev) def get_formatter(repository, readme_file, rev) - raw_readme_text = repository.cat(readme_file.path, rev) + raw_readme_text = Redmine::CodesetUtil.to_utf8_by_setting(repository.cat(readme_file.path, rev)) if MARKDOWN_EXT.include?(File.extname(readme_file.path)) formatter_name = Redmine::WikiFormatting.format_names.find { |name| name =~ /markdown/i }