From 14cfdcc5679c3b1c231a74da21844bfc377e4a2f Mon Sep 17 00:00:00 2001 From: Bukkit/Spigot Date: Wed, 5 Jan 2011 22:45:54 +0000 Subject: [PATCH] Separate InvalidDescriptionException -> InvalidPluginException By: Dinnerbone --- paper-api/src/main/java/org/bukkit/plugin/PluginLoader.java | 2 +- .../main/java/org/bukkit/plugin/java/JavaPluginLoader.java | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/paper-api/src/main/java/org/bukkit/plugin/PluginLoader.java b/paper-api/src/main/java/org/bukkit/plugin/PluginLoader.java index a652b4bacf..d8a266449f 100644 --- a/paper-api/src/main/java/org/bukkit/plugin/PluginLoader.java +++ b/paper-api/src/main/java/org/bukkit/plugin/PluginLoader.java @@ -19,7 +19,7 @@ public interface PluginLoader { * unsuccessful * @throws InvalidPluginException Thrown when the specified file is not a plugin */ - public Plugin loadPlugin(File file) throws InvalidPluginException; + public Plugin loadPlugin(File file) throws InvalidPluginException, InvalidDescriptionException; /** * Returns a list of all filename filters expected by this PluginLoader diff --git a/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java b/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java index 2c9b507810..f0d7d13c2a 100644 --- a/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java +++ b/paper-api/src/main/java/org/bukkit/plugin/java/JavaPluginLoader.java @@ -41,7 +41,7 @@ public final class JavaPluginLoader implements PluginLoader { server = instance; } - public Plugin loadPlugin(File file) throws InvalidPluginException { + public Plugin loadPlugin(File file) throws InvalidPluginException, InvalidDescriptionException { JavaPlugin result = null; PluginDescriptionFile description = null; @@ -63,8 +63,6 @@ public final class JavaPluginLoader implements PluginLoader { jar.close(); } catch (IOException ex) { throw new InvalidPluginException(ex); - } catch (InvalidDescriptionException ex) { - throw new InvalidPluginException(ex); } try {