From a8c55e5c163ad7e8d6028be2c4feee20e4c1f22d Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Mon, 27 Apr 2015 19:21:55 +0200 Subject: [PATCH] Ignore leading zeros when filtering color codes --- src/main/java/net/pterodactylus/irc/util/MessageCleaner.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/java/net/pterodactylus/irc/util/MessageCleaner.java b/src/main/java/net/pterodactylus/irc/util/MessageCleaner.java index 160811e..33bde94 100644 --- a/src/main/java/net/pterodactylus/irc/util/MessageCleaner.java +++ b/src/main/java/net/pterodactylus/irc/util/MessageCleaner.java @@ -94,6 +94,8 @@ public class MessageCleaner { if (inColorCode == 1) { if ((c < '0') || (c > '9')) { inColorCode = 0; + } else if (c == '0') { + continue; } else { if (c == '9') { inColorCode = 8; -- 2.7.4