aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorGravatar jesopo2018-11-26 17:31:56 +0000
committerGravatar jesopo2018-11-26 17:31:56 +0000
commit9a614846b00a8c498291f40aba1139d822d9f571 (patch)
tree020d7f3886a17e2299625e3ed29d5858f2aa615d /src
parentIf a color code is double-digit, make sure it's 0-15, not just 0-20 (diff)
signature
Don't reject 6-9 (inclusive) when it's prepended by 0 (src/utils/irc.py)
Diffstat (limited to 'src')
-rw-r--r--src/utils/irc.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/utils/irc.py b/src/utils/irc.py
index 09944a6f..df04a885 100644
--- a/src/utils/irc.py
+++ b/src/utils/irc.py
@@ -161,7 +161,7 @@ def _color_tokens(s: str) -> typing.List[str]:
if can_add:
current_color = background if is_background else foreground
if current_color:
- can_add = int(current_color) < 2 and int(char) < 6
+ can_add = int(char) < 6 or int(current_color) < 2
if can_add:
if is_background: