github.com/decred/dcrlnd@v0.7.6/htlcswitch/hop/log.go (about)

     1  package hop
     2  
     3  import (
     4  	"github.com/decred/slog"
     5  )
     6  
     7  // log is a logger that is initialized with no output filters.  This
     8  // means the package will not perform any logging by default until the caller
     9  // requests it.
    10  var log slog.Logger
    11  
    12  // UseLogger uses a specified Logger to output package logging info. This
    13  // function is called from the parent package htlcswitch logger initialization.
    14  func UseLogger(logger slog.Logger) {
    15  	log = logger
    16  }