Fixed server crashes

This commit is contained in:
Frank 2021-08-06 22:26:56 +02:00
parent d4c9695e5c
commit c28a566c78
2 changed files with 14 additions and 8 deletions

View file

@ -29,9 +29,17 @@ public class DataExchangeAPI extends DataExchange {
* You should never need to create a custom instance of this Object.
*/
public DataExchangeAPI() {
super((api) -> new ConnectorClientside(api), (api) -> new ConnectorServerside(api));
super();
}
@Environment(EnvType.CLIENT)
protected ConnectorClientside clientSupplier(DataExchange api) {
return new ConnectorClientside(api);
}
protected ConnectorServerside serverSupplier(DataExchange api) {
return new ConnectorServerside(api);
}
/**
* Register a mod to participate in the DataExchange.