mirror of
https://hub.spigotmc.org/stash/scm/spigot/bukkit.git
synced 2025-08-21 05:44:17 +00:00
Moved itr.remove() in loadPlugins(). Thanks lahwran!
This was moved so that the loop does not end until it has gone through a whole pass without finding any loadable plugins.
This commit is contained in:
parent
76b85c61ae
commit
0f885de3ba
1 changed files with 2 additions and 2 deletions
|
@ -134,7 +134,6 @@ public final class SimplePluginManager implements PluginManager {
|
|||
|
||||
try {
|
||||
plugin = loadPlugin(file, finalPass);
|
||||
itr.remove();
|
||||
} catch (UnknownDependencyException ex) {
|
||||
if (finalPass) {
|
||||
server.getLogger().log(Level.SEVERE, "Could not load '" + file.getPath() + "' in folder '" + directory.getPath() + "': " + ex.getMessage(), ex);
|
||||
|
@ -154,6 +153,7 @@ public final class SimplePluginManager implements PluginManager {
|
|||
result.add(plugin);
|
||||
allFailed = false;
|
||||
finalPass = false;
|
||||
itr.remove();
|
||||
}
|
||||
}
|
||||
if (finalPass) {
|
||||
|
@ -275,7 +275,7 @@ public final class SimplePluginManager implements PluginManager {
|
|||
if (!pluginCommands.isEmpty()) {
|
||||
commandMap.registerAll(plugin.getDescription().getName(), pluginCommands);
|
||||
}
|
||||
|
||||
|
||||
try {
|
||||
plugin.getPluginLoader().enablePlugin(plugin);
|
||||
} catch (Throwable ex) {
|
||||
|
|
Loading…
Add table
Reference in a new issue