mirror of
https://github.com/gitbucket/gitbucket.git
synced 2025-11-10 23:45:50 +01:00
(refs #445)Fix yen to backslash
This commit is contained in:
@@ -54,9 +54,9 @@ object StringUtil {
|
||||
* @return the converted content
|
||||
*/
|
||||
def convertLineSeparator(content: String, lineSeparator: String): String = {
|
||||
val lf = content.replaceAll("¥r¥n", "¥n").replaceAll("¥r", "¥n")
|
||||
val lf = content.replace("\r\n", "\n").replace("\r", "\n")
|
||||
if(lineSeparator == "CRLF"){
|
||||
lf.replaceAll("¥n", "¥r¥n")
|
||||
lf.replace("\n", "\r\n")
|
||||
} else {
|
||||
lf
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user