0

Fixed NPE

This commit is contained in:
Pepich 2017-05-05 10:10:40 +02:00
parent 538560a8cd
commit df786c7c3e

View File

@ -324,13 +324,18 @@ public final class ModuleLoader implements CoreModule
CommandManager.unregisterAll(commands); CommandManager.unregisterAll(commands);
try try
{ {
loaders.get(module).close(); URLClassLoader loader = loaders.get(module);
if (loader != null)
loader.close();
} }
catch (IOException e) catch (IOException e)
{} {}
finally
{
loaders.remove(module); loaders.remove(module);
} }
} }
}
private static ArrayList<String> getAllHooks(Module module) private static ArrayList<String> getAllHooks(Module module)
{ {