code: func New(url string, client *http.Client) *Firebase {
  	fb := &Firebase{
  		url:            sanitizeURL(url),
  		params:         _url.Values{},
  		clientTimeout:  TimeoutDuration,
  		stopWatching:   make(chan struct{}),
  		watchHeartbeat: defaultHeartbeat,
  		eventFuncs:     map[string]chan struct{}{},
  	}
  	if client == nil {
  		var tr *http.Transport
  		tr = &http.Transport{
  			Dial: func(network, address string) (net.Conn, error) {
  				start := time.Now()
  				c, err := net.DialTimeout(network, address, fb.clientTimeout)
  				tr.ResponseHeaderTimeout = fb.clientTimeout - time.Since(start)
  				return c, err
  			},
  		}
  
  		client = &http.Client{
  			Transport:     tr,
  			CheckRedirect: redirectPreserveHeaders,
  		}
  	}
  
  	fb.client = client
  	return fb
  }
docs: // New creates a new Firebase reference,
  // if client is nil, http.DefaultClient is used.