diff options
Diffstat (limited to 'util/util.go')
-rw-r--r-- | util/util.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/util/util.go b/util/util.go index 7da4671..a56e871 100644 --- a/util/util.go +++ b/util/util.go @@ -238,3 +238,10 @@ func HashBytes(media []byte) string { h.Write(media) return hex.EncodeToString(h.Sum(nil)) } + +func EscapeString(text string) string { + // TODO: not enough + + text = strings.Replace(text, "<", "<", -1) + return text +} |