aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorhannibal2 <24389977+hannibal002@users.noreply.github.com>2024-08-16 11:16:47 +0200
committerGitHub <noreply@github.com>2024-08-16 11:16:47 +0200
commit050e3325c7ebe7b6218618262e6ed955232c870d (patch)
tree39b108cfdd0e66caf6cc1e056787e19a5294098a /src
parent9a886b7a771fa3356b92a9c1a5af315882dc9730 (diff)
downloadskyhanni-050e3325c7ebe7b6218618262e6ed955232c870d.tar.gz
skyhanni-050e3325c7ebe7b6218618262e6ed955232c870d.tar.bz2
skyhanni-050e3325c7ebe7b6218618262e6ed955232c870d.zip
Fix: ConcurrentModificationException in SeaCreatureManager (#2350)
Co-authored-by: hannibal2 <24389977+hannibal00212@users.noreply.github.com>
Diffstat (limited to 'src')
-rw-r--r--src/main/java/at/hannibal2/skyhanni/features/fishing/FishingTimer.kt2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/at/hannibal2/skyhanni/features/fishing/FishingTimer.kt b/src/main/java/at/hannibal2/skyhanni/features/fishing/FishingTimer.kt
index 74cf9294d..012d47f49 100644
--- a/src/main/java/at/hannibal2/skyhanni/features/fishing/FishingTimer.kt
+++ b/src/main/java/at/hannibal2/skyhanni/features/fishing/FishingTimer.kt
@@ -125,7 +125,7 @@ object FishingTimer {
private fun handle() {
if (lastSeaCreatureFished.passedSince() > 2.seconds) return
val name = lastNameFished ?: return
- val mobs = recentMobs.filter { it.name == name && it !in mobDespawnTime }
+ val mobs = recentMobs.toSet().filter { it.name == name && it !in mobDespawnTime }
.sortedBy { it.baseEntity.distanceToPlayer() }
.take(mobsToFind).ifEmpty { return }
mobsToFind -= mobs.size