Skip to content
Myr

Fix nl2br example in documentation (#2054)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Ronan Amicel · committed by GitHub · parent ada0a9a · Browse files · 1 file+2 added−2 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+2 added−2 removed

  • other:+2 added−2 removed

1 file+2 added−2 removed

modified:docs/api.rst+2 added-2 removed
695 unmodified lines
696 value = escape(value)697 br = Markup(br)698699 result = "\n\n".join(700 f"<p>{br.join(p.splitlines())}<\p>"700 f"<p>{br.join(p.splitlines())}</p>"701 for p in re.split(r"(?:\r\n|\r(?!\n)|\n){2,}", value)702 )703 return Markup(result) if autoescape else result703 return Markup(result) if eval_ctx.autoescape else result704705706.. _writing-tests:707
212 unmodified lines