File tree Expand file tree Collapse file tree 4 files changed +4
-4
lines changed
lib/logger_json/formatters Expand file tree Collapse file tree 4 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ defmodule LoggerJSON.Formatters.Basic do
2626 conn] a
2727
2828 @ impl Formatter
29- def new ( opts ) do
29+ def new ( opts \\ [ ] ) do
3030 opts = Keyword . new ( opts )
3131 encoder_opts = Keyword . get_lazy ( opts , :encoder_opts , & Formatter . default_encoder_opts / 0 )
3232 metadata_keys_or_selector = Keyword . get ( opts , :metadata , [ ] )
Original file line number Diff line number Diff line change @@ -51,7 +51,7 @@ defmodule LoggerJSON.Formatters.Datadog do
5151 @ processed_metadata_keys ~w[ pid file line mfa conn] a
5252
5353 @ impl Formatter
54- def new ( opts ) do
54+ def new ( opts \\ [ ] ) do
5555 opts = Keyword . new ( opts )
5656 encoder_opts = Keyword . get_lazy ( opts , :encoder_opts , & Formatter . default_encoder_opts / 0 )
5757 redactors = Keyword . get ( opts , :redactors , [ ] )
Original file line number Diff line number Diff line change @@ -144,7 +144,7 @@ defmodule LoggerJSON.Formatters.Elastic do
144144 conn] a
145145
146146 @ impl Formatter
147- def new ( opts ) do
147+ def new ( opts \\ [ ] ) do
148148 opts = Keyword . new ( opts )
149149 encoder_opts = Keyword . get_lazy ( opts , :encoder_opts , & Formatter . default_encoder_opts / 0 )
150150 metadata_keys_or_selector = Keyword . get ( opts , :metadata , [ ] )
Original file line number Diff line number Diff line change @@ -109,7 +109,7 @@ defmodule LoggerJSON.Formatters.GoogleCloud do
109109 @ default_levels_reported_as_errors ~w[ emergency alert critical error] a
110110
111111 @ impl Formatter
112- def new ( opts ) do
112+ def new ( opts \\ [ ] ) do
113113 opts = Keyword . new ( opts )
114114 encoder_opts = Keyword . get_lazy ( opts , :encoder_opts , & Formatter . default_encoder_opts / 0 )
115115 redactors = Keyword . get ( opts , :redactors , [ ] )
You can’t perform that action at this time.
0 commit comments