Split auth server into separate method

This commit is contained in:
fullwall 2016-08-02 00:47:52 +08:00
parent 28b0c4fdc3
commit a18b55b5f7
2 changed files with 6 additions and 2 deletions

View File

@ -258,7 +258,7 @@ public class NMSImpl implements NMSBridge {
.getAuthenticationService();
URL url = HttpAuthenticationService
.constantURL(Setting.AUTH_SERVER_URL.asString() + UUIDTypeAdapter.fromUUID(profile.getId()));
.constantURL(getAuthServerBaseUrl() + UUIDTypeAdapter.fromUUID(profile.getId()));
url = HttpAuthenticationService.concatenateURL(url, "unsigned=" + !requireSecure);
@ -274,6 +274,10 @@ public class NMSImpl implements NMSBridge {
return result;
}
public String getAuthServerBaseUrl() {
return Setting.AUTH_SERVER_URL.asString();
}
@Override
public BossBar getBossBar(org.bukkit.entity.Entity entity) {
BossBattleServer bserver = null;

View File

@ -76,7 +76,7 @@ public class ProfileFetcher {
if (request == null)
return;
try {
try {
request.setResult(NMS.fillProfileProperties(profile, true), ProfileFetchResult.SUCCESS);
} catch (Exception e) {
if (Messaging.isDebugging()) {