Fix sending messages on Velocity proxies

This commit is contained in:
Luck committed 2020-10-15 23:35:59 +01:00
1 parent 6e7c49488d
commit b6e5b0bd47
7 files changed
+118 -26

No files matched your search

@@ -78,7 +78,6 @@ public abstract class AbstractLuckPermsPlugin implements LuckPermsPlugin {
private PermissionRegistry permissionRegistry;
private LogDispatcher logDispatcher;
private LuckPermsConfiguration configuration;
private OkHttpClient httpClient;
private BytebinClient bytebin;
private FileWatcher fileWatcher = null;
private Storage storage;
@@ -119,11 +118,11 @@ public abstract class AbstractLuckPermsPlugin implements LuckPermsPlugin {
this.configuration = new LuckPermsConfiguration(this, provideConfigurationAdapter());
// setup a bytebin instance
this.httpClient = new OkHttpClient.Builder()
OkHttpClient httpClient = new OkHttpClient.Builder()
.callTimeout(15, TimeUnit.SECONDS)
.build();
this.bytebin = new BytebinClient(this.httpClient, getConfiguration().get(ConfigKeys.BYTEBIN_URL), "luckperms");
this.bytebin = new BytebinClient(httpClient, getConfiguration().get(ConfigKeys.BYTEBIN_URL), "luckperms");
// now the configuration is loaded, we can create a storage factory and load initial dependencies
StorageFactory storageFactory = new StorageFactory(this);
@@ -317,11 +316,6 @@ public abstract class AbstractLuckPermsPlugin implements LuckPermsPlugin {
return this.configuration;
}
@Override
public OkHttpClient getHttpClient() {
return this.httpClient;
}
@Override
public BytebinClient getBytebin() {
return this.bytebin;
@@ -57,8 +57,6 @@ import me.lucko.luckperms.common.verbose.VerboseHandler;
import net.luckperms.api.query.QueryOptions;
import okhttp3.OkHttpClient;
import java.util.Collections;
import java.util.List;
import java.util.Optional;
@@ -234,13 +232,6 @@ public interface LuckPermsPlugin {
*/
Optional<FileWatcher> getFileWatcher();
/**
* Gets the http client used by the plugin.
*
* @return the http client
*/
OkHttpClient getHttpClient();
/**
* Gets the bytebin instance in use by platform.
*