View Source LoggerJSON.Redactors.RedactKeys (logger_json v6.0.3)

A simple redactor which replace the value of the keys with "[REDACTED]".

It takes list of keys to redact as an argument, eg.:

config :logger, :default_handler,
  formatter: {LoggerJSON.Formatters.Basic, redactors: [
    {LoggerJSON.Redactors.RedactKeys, ["password"]}

Keep in mind that the key will be converted to binary before sending it to the redactor.



Link to this function

redact(key, value, keys)

View Source

Callback implementation for LoggerJSON.Redactor.redact/3.