mirror of
https://github.com/cnaude/PurpleIRC-spigot.git
synced 2024-11-25 19:45:54 +01:00
Null pointer exception catch
This commit is contained in:
parent
91920953c6
commit
790a69a485
@ -506,7 +506,13 @@ public class ChatTokenizer {
|
||||
effectiveName = "";
|
||||
}
|
||||
String translatedColor = DiscordSRV.getPlugin().getColors().get(hex);
|
||||
String colorCode = ChatColor.translateAlternateColorCodes('&', translatedColor);
|
||||
String colorCode;
|
||||
try {
|
||||
colorCode = ChatColor.translateAlternateColorCodes('&', translatedColor);
|
||||
} catch (Exception ex) {
|
||||
colorCode = "";
|
||||
plugin.logDebug(ex.getMessage());
|
||||
}
|
||||
if (colorCode == null) {
|
||||
colorCode = "";
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user