mirror of
https://github.com/cnaude/PurpleIRC-spigot.git
synced 2024-11-29 13:36:04 +01:00
Update IRC away status correctly in /irc list command when user returns.
This commit is contained in:
parent
19aacbf847
commit
d5a8f53579
2
pom.xml
2
pom.xml
@ -97,7 +97,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.cnaude.pircbotx</groupId>
|
<groupId>com.cnaude.pircbotx</groupId>
|
||||||
<artifactId>pircbotx</artifactId>
|
<artifactId>pircbotx</artifactId>
|
||||||
<version>2.1.4</version>
|
<version>2.1.5</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- Following dependency is provided by CraftBukkit -->
|
<!-- Following dependency is provided by CraftBukkit -->
|
||||||
|
@ -2084,6 +2084,7 @@ public final class PurpleBot {
|
|||||||
public void sendUserWhois(CommandSender sender, String nick) {
|
public void sendUserWhois(CommandSender sender, String nick) {
|
||||||
User user = null;
|
User user = null;
|
||||||
for (Channel channel : getChannels()) {
|
for (Channel channel : getChannels()) {
|
||||||
|
bot.sendRaw().rawLineNow("WHO " + channel.getName());
|
||||||
for (User u : channel.getUsers()) {
|
for (User u : channel.getUsers()) {
|
||||||
if (u.getNick().equals(nick)) {
|
if (u.getNick().equals(nick)) {
|
||||||
user = u;
|
user = u;
|
||||||
@ -2142,7 +2143,7 @@ public final class PurpleBot {
|
|||||||
String n = user.getNick();
|
String n = user.getNick();
|
||||||
n = getNickPrefix(user, channel) + n;
|
n = getNickPrefix(user, channel) + n;
|
||||||
if (user.isAway()) {
|
if (user.isAway()) {
|
||||||
n = n + ChatColor.GRAY + " | Away";
|
n = n + ChatColor.GRAY + " | Away | " + user.getAwayMessage();
|
||||||
}
|
}
|
||||||
if (n.equals(bot.getNick())) {
|
if (n.equals(bot.getNick())) {
|
||||||
n = ChatColor.DARK_PURPLE + n;
|
n = ChatColor.DARK_PURPLE + n;
|
||||||
|
Loading…
Reference in New Issue
Block a user