From 1f8152c3a52e482a01fa84eef45b75eae05c99d1 Mon Sep 17 00:00:00 2001 From: Andrew Steinborn Date: Sun, 16 Sep 2018 13:16:16 -0400 Subject: [PATCH] ProxyServer#getServerInfo -> ProxyServer#getServer --- .../main/java/com/velocitypowered/api/proxy/ProxyServer.java | 2 +- .../src/main/java/com/velocitypowered/proxy/VelocityServer.java | 2 +- .../java/com/velocitypowered/proxy/command/ServerCommand.java | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/api/src/main/java/com/velocitypowered/api/proxy/ProxyServer.java b/api/src/main/java/com/velocitypowered/api/proxy/ProxyServer.java index eb2edcbe1..553e88c10 100644 --- a/api/src/main/java/com/velocitypowered/api/proxy/ProxyServer.java +++ b/api/src/main/java/com/velocitypowered/api/proxy/ProxyServer.java @@ -50,7 +50,7 @@ public interface ProxyServer { * @param name the name of the server * @return the registered server, which may be empty */ - Optional getServerInfo(String name); + Optional getServer(String name); /** * Retrieves all {@link RegisteredServer}s registered with this proxy. diff --git a/proxy/src/main/java/com/velocitypowered/proxy/VelocityServer.java b/proxy/src/main/java/com/velocitypowered/proxy/VelocityServer.java index 55a2ba4c7..b9711f915 100644 --- a/proxy/src/main/java/com/velocitypowered/proxy/VelocityServer.java +++ b/proxy/src/main/java/com/velocitypowered/proxy/VelocityServer.java @@ -264,7 +264,7 @@ public class VelocityServer implements ProxyServer { } @Override - public Optional getServerInfo(String name) { + public Optional getServer(String name) { Preconditions.checkNotNull(name, "name"); return servers.getServer(name); } diff --git a/proxy/src/main/java/com/velocitypowered/proxy/command/ServerCommand.java b/proxy/src/main/java/com/velocitypowered/proxy/command/ServerCommand.java index 3707a800c..2926bb038 100644 --- a/proxy/src/main/java/com/velocitypowered/proxy/command/ServerCommand.java +++ b/proxy/src/main/java/com/velocitypowered/proxy/command/ServerCommand.java @@ -35,7 +35,7 @@ public class ServerCommand implements Command { if (args.length == 1) { // Trying to connect to a server. String serverName = args[0]; - Optional toConnect = server.getServerInfo(serverName); + Optional toConnect = server.getServer(serverName); if (!toConnect.isPresent()) { player.sendMessage(TextComponent.of("Server " + serverName + " doesn't exist.", TextColor.RED)); return;