diff --git a/internal/utilities/utilities.go b/internal/utilities/utilities.go index 6a71c38..69f5e56 100644 --- a/internal/utilities/utilities.go +++ b/internal/utilities/utilities.go @@ -1,6 +1,7 @@ package utilities import ( + "regexp" "strings" "time" "unicode" @@ -63,7 +64,10 @@ func FieldFormat(text string) string { } func DisplayNameFormat(text string) string { - return boldmagenta + text + reset + // use this pattern to remove all emoji strings + pattern := regexp.MustCompile(`\s:[A-Za-z0-9]*:`) + + return boldmagenta + pattern.ReplaceAllString(text, "") + reset } func FormatDate(date time.Time) string {