Skip to content

Commit 3618361

Browse files
committed
fix(mobile): strip trailing CRLF in MarkdownCodeBlock content
1 parent 9af8867 commit 3618361

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

apps/mobile/src/features/threads/ThreadFeed.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,7 @@ function MarkdownCodeBlock(props: {
277277
readonly textColor: string;
278278
readonly theme: ReviewDiffTheme;
279279
}) {
280-
const content = props.content.replace(/\n$/, "");
280+
const content = props.content.replace(/\r?\n$/, "");
281281
const languageLabel = props.language?.trim() || "text";
282282
const highlighted = useMarkdownCodeHighlight({
283283
code: content,

0 commit comments

Comments
 (0)