mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-11-28 05:35:44 +01:00
Fixes class not found error.
https://github.com/BentoBoxWorld/bentobox/issues/360
This commit is contained in:
parent
693c6ab17e
commit
3edfd62a6b
@ -114,8 +114,12 @@ public class AddonsManager {
|
|||||||
|
|
||||||
private void loadAddon(File f) {
|
private void loadAddon(File f) {
|
||||||
Addon addon;
|
Addon addon;
|
||||||
// try loading the addon
|
try (JarFile jar = new JarFile(f)) {
|
||||||
try (JarFile jar = new JarFile(f); AddonClassLoader addonClassLoader = new AddonClassLoader(this, addonDescription(jar), f, this.getClass().getClassLoader())) {
|
// try loading the addon
|
||||||
|
// Get description in the addon.yml file
|
||||||
|
YamlConfiguration data = addonDescription(jar);
|
||||||
|
// Load the addon
|
||||||
|
AddonClassLoader addonClassLoader = new AddonClassLoader(this, data, f, this.getClass().getClassLoader());
|
||||||
// Get the addon itself
|
// Get the addon itself
|
||||||
addon = addonClassLoader.getAddon();
|
addon = addonClassLoader.getAddon();
|
||||||
// Initialize some settings
|
// Initialize some settings
|
||||||
|
Loading…
Reference in New Issue
Block a user