Skip to content

Commit

Permalink
Fixed IndexOutOfBounds exception
Browse files Browse the repository at this point in the history
  • Loading branch information
Lenni0451 committed Dec 7, 2021
1 parent 73828bf commit 7462df8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/net/lenni0451/spm/utils/PluginUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,7 @@ public List<Plugin> getPluginsByLoadOrder() {

if (dependPos > pluginPos) {
plugins.remove(pluginPos);
plugins.add(dependPos + 1, plugin);
plugins.add(Math.min(dependPos + 1, plugins.size()), plugin);

i = 0;
}
Expand Down

0 comments on commit 7462df8

Please sign in to comment.