code: func SetOutput() {
  	out, err := LogOutput()
  	if err != nil {
  		log.Fatal(err)
  	}
  
  	if out == nil {
  		out = ioutil.Discard
  	}
  
  	log.SetOutput(out)
  }
docs: // SetOutput checks for a log destination with LogOutput, and calls
  // log.SetOutput with the result. If LogOutput returns nil, SetOutput uses
  // ioutil.Discard. Any error from LogOutout is fatal.