Skip to content

Commit f5d9c6e

Browse files
committed
Bug fixes.
1 parent e21fb2d commit f5d9c6e

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

api/src/main/java/kr/toxicity/healthbar/api/healthbar/HealthBarUpdaterGroup.java

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,9 +16,8 @@ public interface HealthBarUpdaterGroup {
1616

1717
default boolean update() {
1818
var updaters = updaters();
19-
if (updaters.isEmpty()) return false;
2019
updaters.removeIf(u -> !u.update());
21-
return true;
20+
return updaters.isEmpty();
2221
}
2322
default void remove() {
2423
var updaters = updaters();

dist/src/main/kotlin/kr/toxicity/healthbar/player/HealthBarPlayerImpl.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ class HealthBarPlayerImpl(
3838

3939
override fun clear() {
4040
updaterMap.values.removeIf {
41-
it.update()
41+
it.remove()
4242
true
4343
}
4444
}

0 commit comments

Comments
 (0)