1
0
mirror of https://github.com/moparisthebest/Yaaic synced 2024-08-13 16:53:50 -04:00

Execute commands before joining channels

This commit is contained in:
Sebastian Kaspari 2010-04-27 20:24:23 +02:00
parent 1a2b5893f0
commit b1c1a1f5b8

View File

@ -153,6 +153,14 @@ public class IRCConnection extends PircBot
service.sendBroadcast(intent);
// execute commands
CommandParser parser = CommandParser.getInstance();
for (String command : server.getConnectCommands()) {
parser.parse(command, server, server.getConversation(ServerInfo.DEFAULT_NAME), service);
}
// join channels
if (autojoinChannels != null) {
for (String channel : autojoinChannels) {
// Add support for channel keys
@ -163,13 +171,6 @@ public class IRCConnection extends PircBot
joinChannel(channel);
}
}
// execute commands
CommandParser parser = CommandParser.getInstance();
for (String command : server.getConnectCommands()) {
parser.parse(command, server, server.getConversation(ServerInfo.DEFAULT_NAME), service);
}
}
/**