Skip to content

Commit b01a8a0

Browse files
authored
Fix a bug where it failed to add a new line in the end (#123)
1 parent 3c51df7 commit b01a8a0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

remote-content/remote-sources/utils.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -152,10 +152,10 @@ sidebar_position: ${sidebarPosition}
152152
const transformedContent = contentTransform ? contentTransform(content, filename) : content;
153153

154154
// Ensure content ends with a newline before adding the callout
155-
const contentWithNewline = transformedContent.endsWith('\n') ? transformedContent : transformedContent + '\n';
155+
const contentWithNewline = transformedContent + '\n';
156156

157157
return {
158158
filename: newFilename,
159159
content: frontmatter + contentWithNewline + sourceCallout
160160
};
161-
}
161+
}

0 commit comments

Comments
 (0)