feat: add isSupported to ExtrasMessengerPlugin

This commit is contained in:
ChomeNS
2025-03-17 16:55:31 +07:00
parent 7270354573
commit 04fd9e8e17
2 changed files with 9 additions and 2 deletions

View File

@@ -1 +1 @@
1872
1873

View File

@@ -34,6 +34,8 @@ public class ExtrasMessengerPlugin extends Bot.Listener {
public final List<String> registeredChannels = new ArrayList<>();
public boolean isSupported = false;
public ExtrasMessengerPlugin (Bot bot) {
this.bot = bot;
this.chomens_namespace = bot.config.namespace + ":"; // Ex. chomens_bot: (then it will be appended by channel)
@@ -60,7 +62,12 @@ public class ExtrasMessengerPlugin extends Bot.Listener {
channel.equals(EXTRAS_UNREGISTER_KEY.asString()) ||
channel.equals(EXTRAS_MESSAGE_KEY.asString())
)
) return;
) {
isSupported = false;
return;
}
isSupported = true;
final List<String> channels = new ArrayList<>();