cleanup & fix build

This commit is contained in:
Luck
2017-10-29 20:37:29 +00:00
Unverified
parent dee41b315f
commit 230d9725e8
14 changed files with 30 additions and 45 deletions
@@ -197,11 +197,12 @@ public class SpongeUserManager implements UserManager, LPSubjectCollection {
@Override
public CompletableFuture<Void> updateAllUsers() {
return CompletableFuture.supplyAsync(plugin::getOnlinePlayers, plugin.getScheduler().sync())
.thenAcceptAsync(players -> players.forEach(uuid -> {
UUID internal = plugin.getUuidCache().getUUID(uuid);
plugin.getStorage().loadUser(internal, "null").join();
}), plugin.getScheduler().async());
return CompletableFuture.runAsync(
() -> plugin.getOnlinePlayers()
.map(u -> plugin.getUuidCache().getUUID(u))
.forEach(u -> plugin.getStorage().loadUser(u, null).join()),
plugin.getScheduler().async()
);
}
/* ------------------------------------------
@@ -181,7 +181,7 @@ public class MigrationPermissionsEx extends SubCommand<Object> {
}
// Make a LuckPerms user for the one being migrated
plugin.getStorage().loadUser(uuid, "null").join();
plugin.getStorage().loadUser(uuid, null).join();
User user = plugin.getUserManager().getIfLoaded(uuid);
if (user.getEnduringNodes().size() <= 1) {
user.clearNodes(false);