Skip to content
This repository has been archived by the owner on Jul 27, 2019. It is now read-only.

Commit

Permalink
Check for valid version of Shortify.
Browse files Browse the repository at this point in the history
  • Loading branch information
cnaude committed Dec 9, 2014
1 parent 2080ab7 commit 8ea7488
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/main/java/com/cnaude/purpleirc/PurpleIRC.java
Original file line number Diff line number Diff line change
Expand Up @@ -307,8 +307,13 @@ public void onEnable() {
logInfo("DeathMessages not detected.");
}
if (isPluginEnabled("Shortify")) {
logInfo("Enabling Shortify support.");
shortifyHook = new ShortifyHook(this);
String shortifyVersion = getServer().getPluginManager().getPlugin("Shortify").getDescription().getVersion();
if (shortifyVersion.startsWith("1.6")) {
logError("Shortify v" + shortifyVersion + " not supported. Please install 1.7 or newer.");
} else {
logInfo("Enabling Shortify support.");
shortifyHook = new ShortifyHook(this);
}
} else {
logInfo("Shortify not detected.");
}
Expand Down

0 comments on commit 8ea7488

Please sign in to comment.