mirror of
https://github.com/proxiodev/RedisBungee.git
synced 2024-11-23 04:28:01 +00:00
Resolve #35
This commit is contained in:
parent
f5af1aed70
commit
1a14a431c4
@ -199,7 +199,12 @@ public final class RedisBungee extends Plugin {
|
|||||||
|
|
||||||
final Set<UUID> getPlayersOnServer(@NonNull String server) {
|
final Set<UUID> getPlayersOnServer(@NonNull String server) {
|
||||||
checkArgument(getProxy().getServers().containsKey(server), "server does not exist");
|
checkArgument(getProxy().getServers().containsKey(server), "server does not exist");
|
||||||
return ImmutableSet.copyOf((Collection<UUID>) getServerPlayersScript.eval(ImmutableList.<String>of(), ImmutableList.<String>of(server)));
|
Collection<String> asStrings = (Collection<String>) getServerPlayersScript.eval(ImmutableList.<String>of(), ImmutableList.<String>of(server));
|
||||||
|
ImmutableSet.Builder<UUID> builder = ImmutableSet.builder();
|
||||||
|
for (String s : asStrings) {
|
||||||
|
builder.add(UUID.fromString(s));
|
||||||
|
}
|
||||||
|
return builder.build();
|
||||||
}
|
}
|
||||||
|
|
||||||
final void sendProxyCommand(@NonNull String proxyId, @NonNull String command) {
|
final void sendProxyCommand(@NonNull String proxyId, @NonNull String command) {
|
||||||
|
Loading…
Reference in New Issue
Block a user