go-zero/tools/goctl/model/sql/util/newline.go

10 lines
154 B
Go
Raw Normal View History

2021-05-12 12:28:23 +08:00
package util
import "strings"
func TrimNewLine(s string) string {
s = strings.ReplaceAll(s, "\r", "")
s = strings.ReplaceAll(s, "\n", "")
return s
}