Send correct proxy header

This commit is contained in:
9seconds
2018-07-08 13:19:16 +03:00
parent 6adc592490
commit 76e88edac3
4 changed files with 37 additions and 5 deletions
+7 -1
View File
@@ -43,7 +43,13 @@ func (t *MiddleTelegram) Init(connOpts *mtproto.ConnectionOpts, conn wrappers.St
return nil, err
}
return wrappers.NewMTProtoProxy(frameConn, connOpts, t.conf.AdTag)
proxyConn, err := wrappers.NewMTProtoProxy(frameConn, connOpts, t.conf.AdTag)
if err != nil {
return nil, err
}
proxyConn.Logger().Infow("Telegram connection initialized")
return proxyConn, nil
}
func (t *MiddleTelegram) sendRPCNonceRequest(conn wrappers.PacketWriter) (*rpc.NonceRequest, error) {