aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/at/hannibal2/skyhanni/features/chat
diff options
context:
space:
mode:
authorWalker Selby <git@walkerselby.com>2023-12-17 14:06:40 +0000
committerGitHub <noreply@github.com>2023-12-17 15:06:40 +0100
commit2ac57182e9af1e62a4ae5799c8a2451a59017510 (patch)
treefb3bccb5490a80a5a70bd59a3f92bef7d6a39950 /src/main/java/at/hannibal2/skyhanni/features/chat
parent75bcfde81d1494eaa41463e58e5767aa6d09b5a4 (diff)
downloadskyhanni-2ac57182e9af1e62a4ae5799c8a2451a59017510.tar.gz
skyhanni-2ac57182e9af1e62a4ae5799c8a2451a59017510.tar.bz2
skyhanni-2ac57182e9af1e62a4ae5799c8a2451a59017510.zip
Remove unecessary non-capturing groups (#676)
Remove unnecessary non-capturing groups. #676
Diffstat (limited to 'src/main/java/at/hannibal2/skyhanni/features/chat')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/chat/playerchat/PlayerChatModifier.kt6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/chat/playerchat/PlayerChatModifier.kt b/src/main/java/at/hannibal2/skyhanni/features/chat/playerchat/PlayerChatModifier.kt
index a57c5a784..c95763adf 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/chat/playerchat/PlayerChatModifier.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/chat/playerchat/PlayerChatModifier.kt
@@ -15,9 +15,9 @@ class PlayerChatModifier {
private val patterns = mutableListOf<Regex>()
init {
- patterns.add("§[ab6]\\[(?:VIP|MVP)(?:(?:§.|\\+)*)](?: {1,2})(?:§[7ab6])?(\\w{2,16})".toRegex()) // ranked player with prefix everywhere
- patterns.add("§[7ab6]((?:\\w){2,16})§r(?!§7x)(?!\$)".toRegex()) // all players without rank prefix in notification messages
- patterns.add("(?:§7 )?§7((?:\\w){2,16})§7§r".toRegex()) // nons user chat
+ patterns.add("§[ab6]\\[(?:VIP|MVP)(?:§.|\\+)*] {1,2}(?:§[7ab6])?(\\w{2,16})".toRegex()) // ranked player with prefix everywhere
+ patterns.add("§[7ab6](\\w{2,16})§r(?!§7x)(?!\$)".toRegex()) // all players without rank prefix in notification messages
+ patterns.add("(?:§7 )?§7(\\w{2,16})§7§r".toRegex()) // nons user chat
}
@SubscribeEvent