mirror of
https://github.com/BentoBoxWorld/BentoBox.git
synced 2024-12-28 03:57:39 +01:00
Use #getEnabledAddons() in AddonsManager#getGameModeAddons()
This commit is contained in:
parent
f381301b25
commit
eeda960d42
@ -244,8 +244,7 @@ public class AddonsManager {
|
|||||||
* @since 1.1
|
* @since 1.1
|
||||||
*/
|
*/
|
||||||
public List<GameModeAddon> getGameModeAddons() {
|
public List<GameModeAddon> getGameModeAddons() {
|
||||||
return addons.stream()
|
return getEnabledAddons().stream()
|
||||||
.filter(addon -> addon.getState().equals(Addon.State.ENABLED))
|
|
||||||
.filter(GameModeAddon.class::isInstance)
|
.filter(GameModeAddon.class::isInstance)
|
||||||
.map(GameModeAddon.class::cast)
|
.map(GameModeAddon.class::cast)
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
|
Loading…
Reference in New Issue
Block a user