diff options
author | Inglett <inglettronald@gmail.com> | 2024-01-18 15:03:52 -0600 |
---|---|---|
committer | Inglett <inglettronald@gmail.com> | 2024-01-18 15:03:52 -0600 |
commit | 2591eaa363d4c97817fce05988009b6d7d31149a (patch) | |
tree | c3e919cee0328c7f68049ca83fb319514c54e9ba /src | |
parent | 2249182df19085e14c5bd29d466331228677ad3c (diff) | |
download | DulkirMod-Fabric-2591eaa363d4c97817fce05988009b6d7d31149a.tar.gz DulkirMod-Fabric-2591eaa363d4c97817fce05988009b6d7d31149a.tar.bz2 DulkirMod-Fabric-2591eaa363d4c97817fce05988009b6d7d31149a.zip |
fix another garden bug and crash
Diffstat (limited to 'src')
-rw-r--r-- | src/main/kotlin/com/dulkirfabric/util/TablistUtils.kt | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/kotlin/com/dulkirfabric/util/TablistUtils.kt b/src/main/kotlin/com/dulkirfabric/util/TablistUtils.kt index 38c62a7..b731340 100644 --- a/src/main/kotlin/com/dulkirfabric/util/TablistUtils.kt +++ b/src/main/kotlin/com/dulkirfabric/util/TablistUtils.kt @@ -51,7 +51,7 @@ object TablistUtils { persistentInfo.nextVisitorTime = result.groupValues[1] var index = tablist!!.indexOf(it) + 1 var visitors = 0 - while (tablist!!.get(index).displayName?.string != "") { + while (index < tablist!!.size && tablist!![index].displayName?.string != "" && visitors < 5) { index++ visitors++ } |