From d95891256ba19ea4b9b0c30f61aa97cf2052cd08 Mon Sep 17 00:00:00 2001 From: Luck Date: Mon, 14 Nov 2016 18:55:10 +0000 Subject: [PATCH] Setup a users calculated data when loaded by the SubjectCollection --- .../luckperms/sponge/service/collections/UserCollection.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sponge/src/main/java/me/lucko/luckperms/sponge/service/collections/UserCollection.java b/sponge/src/main/java/me/lucko/luckperms/sponge/service/collections/UserCollection.java index 4bf3b7dc4..0453cb50f 100644 --- a/sponge/src/main/java/me/lucko/luckperms/sponge/service/collections/UserCollection.java +++ b/sponge/src/main/java/me/lucko/luckperms/sponge/service/collections/UserCollection.java @@ -110,6 +110,10 @@ public class UserCollection implements SubjectCollection { service.getPlugin().getLog().warn("User Subject '" + u + "' was requested, but is not loaded in memory. Loading them from storage now."); long startTime = System.currentTimeMillis(); service.getPlugin().getStorage().loadUser(u, "null").join(); + User user = service.getPlugin().getUserManager().get(u); + if (user != null) { + user.setupData(false); + } service.getPlugin().getLog().warn("Loading '" + u + "' took " + (System.currentTimeMillis() - startTime) + " ms."); }