From 6645e216d549066623cd92cf8bb06b642ea0f183 Mon Sep 17 00:00:00 2001 From: Auxilor Date: Thu, 18 May 2023 15:35:47 +0100 Subject: [PATCH] Fixed stupid profile saver bug --- .../eco/internal/spigot/data/storage/ProfileSaver.kt | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/eco-core/core-plugin/src/main/kotlin/com/willfp/eco/internal/spigot/data/storage/ProfileSaver.kt b/eco-core/core-plugin/src/main/kotlin/com/willfp/eco/internal/spigot/data/storage/ProfileSaver.kt index 56497287e..b44017c87 100644 --- a/eco-core/core-plugin/src/main/kotlin/com/willfp/eco/internal/spigot/data/storage/ProfileSaver.kt +++ b/eco-core/core-plugin/src/main/kotlin/com/willfp/eco/internal/spigot/data/storage/ProfileSaver.kt @@ -18,12 +18,7 @@ class ProfileSaver( val uuid = iterator.next() iterator.remove() - val profile = handler.accessLoadedProfile(uuid) - - if (profile == null) { - iterator.remove() - continue - } + val profile = handler.accessLoadedProfile(uuid) ?: continue handler.saveKeysFor(uuid, profile.data.keys) }