Yep. Fixed

This commit is contained in:
qowevisa 2024-06-12 22:47:40 +03:00
parent fed848e403
commit 61f80b82c7

View File

@ -110,7 +110,7 @@ func readFromServer(conn net.Conn, ws *websocket.Conn) {
msg.Data = tmpLink.Data msg.Data = tmpLink.Data
// Crypto stuff // Crypto stuff
case com.ID_CLIENT_SEND_CLIENT_ECDH_PUBKEY: case com.ID_CLIENT_SEND_CLIENT_ECDH_PUBKEY:
t, err := tlepCenter.GetTLEP(msg.ToID) t, err := tlepCenter.GetTLEP(msg.FromID)
if err != nil { if err != nil {
log.Printf("ERROR: tlep: GetTLEP: %v\n", err) log.Printf("ERROR: tlep: GetTLEP: %v\n", err)
continue continue
@ -122,7 +122,7 @@ func readFromServer(conn net.Conn, ws *websocket.Conn) {
} }
msg.Data = []byte{} msg.Data = []byte{}
case com.ID_CLIENT_SEND_CLIENT_CBES_SPECS: case com.ID_CLIENT_SEND_CLIENT_CBES_SPECS:
t, err := tlepCenter.GetTLEP(msg.ToID) t, err := tlepCenter.GetTLEP(msg.FromID)
if err != nil { if err != nil {
log.Printf("ERROR: tlep: GetTLEP: %v\n", err) log.Printf("ERROR: tlep: GetTLEP: %v\n", err)
continue continue
@ -139,7 +139,7 @@ func readFromServer(conn net.Conn, ws *websocket.Conn) {
} }
// message // message
case com.ID_CLIENT_SEND_CLIENT_MESSAGE: case com.ID_CLIENT_SEND_CLIENT_MESSAGE:
t, err := tlepCenter.GetTLEP(msg.ToID) t, err := tlepCenter.GetTLEP(msg.FromID)
if err != nil { if err != nil {
log.Printf("ERROR: tlep: GetTLEP: %v\n", err) log.Printf("ERROR: tlep: GetTLEP: %v\n", err)
continue continue