Skip to content

Restore translator locale when body rendering fails #19

Description

@javihgil

TranslatableBodyRenderer switches the translator locale to render a translated email body, but if the wrapped renderer throws an exception the original locale is not restored.

That leaves the translator in the wrong state for the rest of the request.

The renderer should always restore the original locale, typically with safe cleanup logic around the wrapped render call.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions