Fixed 122 errors - by fixing the pom
Also other fixes
This commit is contained in:
parent
d12fe961c0
commit
9527be99d1
3 changed files with 20 additions and 3 deletions
18
pom.xml
18
pom.xml
|
@ -106,6 +106,7 @@
|
||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||||
|
<branch>master</branch> <!-- Should be master if building ButtonCore locally -->
|
||||||
</properties>
|
</properties>
|
||||||
|
|
||||||
<repositories>
|
<repositories>
|
||||||
|
@ -173,7 +174,7 @@
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.github.TBMCPlugins.ButtonCore</groupId>
|
<groupId>com.github.TBMCPlugins.ButtonCore</groupId>
|
||||||
<artifactId>ButtonCore</artifactId>
|
<artifactId>ButtonCore</artifactId>
|
||||||
<version>${env.TRAVIS_BRANCH}-SNAPSHOT</version>
|
<version>${branch}-SNAPSHOT</version>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
|
@ -225,4 +226,19 @@
|
||||||
<version>4.0.0</version>
|
<version>4.0.0</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
|
<profiles>
|
||||||
|
<profile>
|
||||||
|
<id>ci</id>
|
||||||
|
<activation>
|
||||||
|
<property>
|
||||||
|
<name>env.TRAVIS_BRANCH</name>
|
||||||
|
</property>
|
||||||
|
</activation>
|
||||||
|
<properties>
|
||||||
|
<!-- Override only if necessary -->
|
||||||
|
<branch>${env.TRAVIS_BRANCH}</branch>
|
||||||
|
</properties>
|
||||||
|
</profile>
|
||||||
|
</profiles>
|
||||||
</project>
|
</project>
|
||||||
|
|
|
@ -51,6 +51,7 @@ public abstract class DiscordSenderBase implements CommandSender {
|
||||||
public void sendMessage(String message) {
|
public void sendMessage(String message) {
|
||||||
try {
|
try {
|
||||||
final boolean broadcast = new Exception().getStackTrace()[2].getMethodName().contains("broadcast");
|
final boolean broadcast = new Exception().getStackTrace()[2].getMethodName().contains("broadcast");
|
||||||
|
//if (broadcast && DiscordPlugin.hooked) - TODO: What should happen if unhooked
|
||||||
if (broadcast)
|
if (broadcast)
|
||||||
return;
|
return;
|
||||||
final String sendmsg = DPUtils.sanitizeString(message);
|
final String sendmsg = DPUtils.sanitizeString(message);
|
||||||
|
|
|
@ -39,8 +39,8 @@ import sx.blah.discord.util.MissingPermissionsException;
|
||||||
import javax.annotation.Nullable;
|
import javax.annotation.Nullable;
|
||||||
import java.awt.*;
|
import java.awt.*;
|
||||||
import java.time.Instant;
|
import java.time.Instant;
|
||||||
import java.util.*;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.*;
|
||||||
import java.util.concurrent.LinkedBlockingQueue;
|
import java.util.concurrent.LinkedBlockingQueue;
|
||||||
import java.util.concurrent.TimeoutException;
|
import java.util.concurrent.TimeoutException;
|
||||||
import java.util.function.Consumer;
|
import java.util.function.Consumer;
|
||||||
|
@ -81,7 +81,7 @@ public class MCChatListener implements Listener, IListener<MessageReceivedEvent>
|
||||||
time = se.getValue();
|
time = se.getValue();
|
||||||
|
|
||||||
final String authorPlayer = "[" + DPUtils.sanitizeStringNoEscape(e.getChannel().DisplayName) + "] " //
|
final String authorPlayer = "[" + DPUtils.sanitizeStringNoEscape(e.getChannel().DisplayName) + "] " //
|
||||||
+ ("Minecraft".equals(e.getOrigin()) ? "" : "[" + e.getOrigin() + "]") //
|
+ ("Minecraft".equals(e.getOrigin()) ? "" : "[" + e.getOrigin().substring(0, 1) + "]") //
|
||||||
+ (DPUtils.sanitizeStringNoEscape(e.getSender() instanceof Player //
|
+ (DPUtils.sanitizeStringNoEscape(e.getSender() instanceof Player //
|
||||||
? ((Player) e.getSender()).getDisplayName() //
|
? ((Player) e.getSender()).getDisplayName() //
|
||||||
: e.getSender().getName()));
|
: e.getSender().getName()));
|
||||||
|
|
Loading…
Reference in a new issue