diff --git a/pom.xml b/pom.xml
index c487ae1..d5b838d 100644
--- a/pom.xml
+++ b/pom.xml
@@ -6,7 +6,7 @@
org.openautonomousconnection
protocol
- 1.0.0-BETA.5
+ 1.0.0-BETA.5.1
Open Autonomous Connection
https://open-autonomous-connection.org/
diff --git a/src/main/java/org/openautonomousconnection/protocol/ProtocolBridge.java b/src/main/java/org/openautonomousconnection/protocol/ProtocolBridge.java
index 6a80631..51bddf8 100644
--- a/src/main/java/org/openautonomousconnection/protocol/ProtocolBridge.java
+++ b/src/main/java/org/openautonomousconnection/protocol/ProtocolBridge.java
@@ -105,8 +105,6 @@ public final class ProtocolBridge {
*/
@ProtocolInfo(protocolSide = ProtocolVersion.ProtocolSide.INS)
public ProtocolBridge(ProtocolINSServer protocolINSServer, ProtocolSettings protocolSettings, ProtocolVersion protocolVersion, File logFolder) throws Exception {
- protocolINSServer.attachBridge(this);
-
// Assign the parameters to the class fields
this.protocolINSServer = protocolINSServer;
this.protocolSettings = protocolSettings;
@@ -119,6 +117,9 @@ public final class ProtocolBridge {
// Register the appropriate listeners and packets
registerListeners();
registerPackets();
+
+ // Assign Bridge
+ protocolINSServer.attachBridge(this);
}
/**
@@ -132,8 +133,6 @@ public final class ProtocolBridge {
*/
@ProtocolInfo(protocolSide = ProtocolVersion.ProtocolSide.WEB)
public ProtocolBridge(ProtocolWebServer protocolWebServer, ProtocolSettings protocolSettings, ProtocolVersion protocolVersion, File logFolder) throws Exception {
- protocolWebServer.attachBridge(this);
-
// Assign the parameters to the class fields
this.protocolWebServer = protocolWebServer;
this.protocolSettings = protocolSettings;
@@ -146,6 +145,9 @@ public final class ProtocolBridge {
// Register the appropriate listeners and packets
registerListeners();
registerPackets();
+
+ // Assign Bridge
+ protocolINSServer.attachBridge(this);
}
/**
@@ -159,8 +161,6 @@ public final class ProtocolBridge {
*/
@ProtocolInfo(protocolSide = ProtocolVersion.ProtocolSide.CLIENT)
public ProtocolBridge(ProtocolClient protocolClient, ProtocolSettings protocolSettings, ProtocolVersion protocolVersion, File logFolder) throws Exception {
- protocolClient.attachBridge(this);
-
// Assign the parameters to the class fields
this.protocolClient = protocolClient;
this.protocolSettings = protocolSettings;
@@ -173,6 +173,9 @@ public final class ProtocolBridge {
// Register the appropriate listeners and packets
registerListeners();
registerPackets();
+
+ // Assign Bridge
+ protocolINSServer.attachBridge(this);
}
/**
diff --git a/src/main/java/org/openautonomousconnection/protocol/side/ins/ProtocolINSServer.java b/src/main/java/org/openautonomousconnection/protocol/side/ins/ProtocolINSServer.java
index 7e8518f..aa07bc9 100644
--- a/src/main/java/org/openautonomousconnection/protocol/side/ins/ProtocolINSServer.java
+++ b/src/main/java/org/openautonomousconnection/protocol/side/ins/ProtocolINSServer.java
@@ -86,8 +86,6 @@ public abstract class ProtocolINSServer extends DefaultMethodsOverrider {
checkFileExists(folderStructure.publicServerFolder, folderStructure.certPrefix, ".crt");
checkFileExists(folderStructure.privateServerFolder, folderStructure.certPrefix, ".key");
-
-
// Initialize the protocol bridge and clients list
this.clients = new ArrayList<>();