Skip to content
This repository was archived by the owner on Dec 8, 2020. It is now read-only.

Commit 7c9905d

Browse files
committed
Add better docs
1 parent 1daf65c commit 7c9905d

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

lib/timber/config.ex

+11
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,17 @@ defmodule Timber.Config do
4444
@doc """
4545
Allows for the sanitizations of custom header keys. This should be used to
4646
ensure sensitive data, such as API keys, do not get logged.
47+
48+
**Note, the keys passed must be lowercase!**
49+
50+
Timber normalizes headers to be downcased before comparing them here. For
51+
performance reasons it is advised that you pass lower cased keys.
52+
53+
# Example
54+
55+
```elixir
56+
config :timber, :header_keys_to_sanitize, ["my-sensitive-header-name"]
57+
```
4758
"""
4859
def header_keys_to_sanitize, do: Application.get_env(@application, :header_keys_to_sanitize, [])
4960

0 commit comments

Comments
 (0)