mirror of
https://github.com/ScuroNeko/mtg.git
synced 2026-08-31 23:34:02 +03:00
linting the code
This commit is contained in:
@@ -17,6 +17,7 @@ func TelegramProtocol(req *protocol.TelegramRequest) (conntypes.StreamReadWriteC
|
||||
if err != nil {
|
||||
return nil, fmt.Errorf("cannot dial to telegram: %w", err)
|
||||
}
|
||||
|
||||
conn = stream.NewTimeout(conn)
|
||||
conn = stream.NewCtx(req.Ctx, req.Cancel, conn)
|
||||
fm := generateFrame(req.ClientProtocol)
|
||||
@@ -45,6 +46,7 @@ func generateFrame(cp protocol.ClientProtocol) (fm Frame) {
|
||||
if _, err := rand.Read(data); err != nil {
|
||||
continue
|
||||
}
|
||||
|
||||
if data[0] == 0xef {
|
||||
continue
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user