Mailglass.Credo.NoFullResponseInLogs (Mailglass v1.0.0)

Copy Markdown View Source

Basics

This check is disabled by default.

Learn how to enable it via .credo.exs.

This check has a base priority of high and works with any version of Elixir.

Explanation

Avoid logging full provider responses at info/warning/error levels.

Check-Specific Parameters

Use the following parameters to configure this check:

:levels

Logger levels to inspect.

This parameter defaults to [:info, :warning, :error].

:included_path_prefixes

Only files in these path prefixes are linted.

This parameter defaults to ["lib/mailglass/"].

:suspicious_fragments

Variable-name fragments treated as response payload hints.

This parameter defaults to ["response", "resp", "body", "payload"].

General Parameters

Like with all checks, general params can be applied.

Parameters can be configured via the .credo.exs config file.