Added extra parenthesis

This commit is contained in:
Norbi Peti 2016-12-25 01:03:05 +01:00
parent bf33c55205
commit 9269e0fb19

View file

@ -21,8 +21,13 @@ public class AutoUpdaterListener implements IListener<MessageReceivedEvent> {
return;
String branch = title.substring(title.indexOf(':') + 1, title.indexOf(']'));
String project = title.substring(title.indexOf('[') + 1, title.indexOf(':'));
if (branch.equals("master") || (TBMCCoreAPI.IsTestServer() && branch.equals("dev"))
&& TBMCCoreAPI.UpdatePlugin(project, new DiscordSender(null, TBMCCoreAPI.IsTestServer()?DiscordPlugin.chatchannel:DiscordPlugin.coffeechannel), branch)
if ((branch.equals("master") || (TBMCCoreAPI.IsTestServer() && branch.equals("dev")))
&& TBMCCoreAPI.UpdatePlugin(project,
new DiscordSender(null,
TBMCCoreAPI.IsTestServer() //
? DiscordPlugin.chatchannel //
: DiscordPlugin.coffeechannel),
branch)
&& (!TBMCCoreAPI.IsTestServer() || !branch.equals("master")))
try {
event.getMessage().addReaction(DiscordPlugin.DELIVERED_REACTION);