diff options
| author | 2019-11-11 12:40:36 +0000 | |
|---|---|---|
| committer | 2019-11-11 12:40:36 +0000 | |
| commit | 727fb3427d3121553e5c73cb171bc9c1f038fe91 (patch) | |
| tree | 9c67d7f6d5eaba5f4603f08ce77783210592b7c5 /src/utils/irc.py | |
| parent | add bot-wide option to colorize nicknames in formatted output (diff) | |
| signature | ||
.lower() strings when hash-colorizing them
Diffstat (limited to 'src/utils/irc.py')
| -rw-r--r-- | src/utils/irc.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/utils/irc.py b/src/utils/irc.py index d44825d8..91a4cc4f 100644 --- a/src/utils/irc.py +++ b/src/utils/irc.py @@ -43,7 +43,7 @@ def color(s: str, foreground: consts.IRCColor, HASH_COLORS = list(range(2, 16)) def hash_colorize(s: str): - code = sum(ord(c) for c in s)%len(HASH_COLORS) + code = sum(ord(c) for c in s.lower())%len(HASH_COLORS) return color(s, consts.COLOR_CODES[code]) def bold(s: str) -> str: |
