shared/logger/toplevel: The toplevel AddContext should use the top level logger

Rather than accept an argument, to avoid confusion.

Because it is using the top level logger as the basis for the new logger and not
using the passed in logger.

Signed-off-by: Thomas Parrott <thomas.parrott@canonical.com>
This commit is contained in:
Thomas Parrott 2023-05-19 10:04:18 +01:00
parent d4f88a91d3
commit 421eda293d

View File

@ -65,6 +65,6 @@ func Panicf(format string, args ...any) {
}
// AddContext returns a new logger with the context added.
func AddContext(logger Logger, ctx Ctx) Logger {
func AddContext(ctx Ctx) Logger {
return Log.AddContext(ctx)
}