forked from SteamWar/SteamWar
Fix AbstractLinker
This commit is contained in:
@@ -124,6 +124,7 @@ public class BauSystem extends JavaPlugin implements Listener {
|
|||||||
} catch (AbstractLinker.LinkException e) {
|
} catch (AbstractLinker.LinkException e) {
|
||||||
getLogger().log(Level.SEVERE, "Could not link a class.", e);
|
getLogger().log(Level.SEVERE, "Could not link a class.", e);
|
||||||
Bukkit.shutdown();
|
Bukkit.shutdown();
|
||||||
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
TickListener.impl.init();
|
TickListener.impl.init();
|
||||||
|
|||||||
@@ -45,8 +45,6 @@ public class TraceManager implements Listener {
|
|||||||
instance = this;
|
instance = this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public void init() {
|
public void init() {
|
||||||
if (!tracesFolder.exists())
|
if (!tracesFolder.exists())
|
||||||
tracesFolder.mkdir();
|
tracesFolder.mkdir();
|
||||||
|
|||||||
@@ -56,7 +56,9 @@ public abstract class AbstractLinker<T> {
|
|||||||
.map(s -> {
|
.map(s -> {
|
||||||
try {
|
try {
|
||||||
return Class.forName(s, false, plugin.getClass().getClassLoader());
|
return Class.forName(s, false, plugin.getClass().getClassLoader());
|
||||||
} catch (ClassNotFoundException | NoClassDefFoundError e) {
|
} catch (NoClassDefFoundError error) {
|
||||||
|
return null;
|
||||||
|
} catch (ClassNotFoundException e) {
|
||||||
throw new SecurityException(e.getMessage(), e);
|
throw new SecurityException(e.getMessage(), e);
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user