Highly-opinionated (ex-bullshit-free) MTPROTO proxy for Telegram. If you use v1.0 or upgrade broke you proxy, please read the chapter Version 2
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

stream_info.go 229B

12345678910111213141516171819
  1. package stats
  2. import (
  3. "net"
  4. "time"
  5. )
  6. type streamInfo struct {
  7. createdAt time.Time
  8. clientIP net.IP
  9. }
  10. func (s *streamInfo) IPType() string {
  11. if s.clientIP.To4() == nil {
  12. return TagIPTypeIPv6
  13. }
  14. return TagIPTypeIPv4
  15. }