]> jfr.im git - irc/rizon/acid.git/commitdiff
Remove now unnecessary command plugin setting
authorAdam <redacted>
Sat, 16 Aug 2014 05:52:05 +0000 (01:52 -0400)
committerAdam <redacted>
Sat, 16 Aug 2014 05:52:05 +0000 (01:52 -0400)
acid/src/main/java/net/rizon/acid/conf/Command.java
acid/src/main/java/net/rizon/acid/core/Acidictive.java

index e3bb86b9606c550e93e95b64d195c33b7ceb0c11..d319d589f04d59e7f138b3cc470820369e937a73 100644 (file)
@@ -9,7 +9,6 @@ public class Command implements Validatable
        public String name, privilege;
        public List<String> channels;
        public String clazz;
-       public String plugin;
        
        public boolean allowsChannel(String channel)
        {
index ad8601eb793dc175cc616aa0eb3235d109680ab8..bb07e2d5fa72b4dc38766599d5bbdb6edf797c9f 100644 (file)
@@ -273,14 +273,10 @@ public class Acidictive extends AcidCore
                        
                        if (confCommand == null)
                                return;
-                       
-                       Plugin p = null;
-                       // If the conf specifies a plugin, use that
-                       if (confCommand.plugin != null)
-                               p = Plugin.findPlugin(confCommand.plugin);
-                       // Otherwise use the plugin of the target, if any 
-                       else
-                               p = to.pkg;
+
+                       // This isn't really necessary, but is faster than causing the core loader to fail and then fall back
+                       // by searching the plugin loaders.
+                       Plugin p = to.pkg;
                        // Use our loader if there is no plugin
                        ClassLoader cl = p != null ? p.loader : loader; 
                        Class<?> commandClass = cl.loadClass(confCommand.clazz);