Skip to content
代码片段 群组 项目
提交 4e055e8a 编辑于 作者: tsl0922's avatar tsl0922
浏览文件

fix: UTF-8 encoding error

上级 ef61d1f2
No related branches found
No related tags found
无相关合并请求
......@@ -109,6 +109,8 @@ def current_ref
else
input = @request.body.read
end
# force utf-8 encoding
input.encode!('UTF-8', 'UTF-8', invalid: :replace, undef: :replace, replace: '')
# Need to reset seek point
@request.body.rewind
/refs\/heads\/([\w\.-]+)/.match(input).to_a.last
......
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册