Skip to content

Commit 991fa27

Browse files
committed
fix(core): pour éviter le bug de répétition du dernier caractère en cas de chatbot avec yaml mais sans titre de niveau 2
1 parent f51730d commit 991fa27

3 files changed

Lines changed: 3 additions & 3 deletions

File tree

app/js/core/chatbot/parsers/getChatbotInformations.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ export function getChatbotInformations(mdWithoutYaml, introduction, yaml) {
1515
const titleLine = chatbotTitle ? "## " + chatbotTitle : "## Chatbot";
1616
const introductionContent = titleLine + "\n" + initialMessage + "\n";
1717
const chatbotContent =
18-
introductionContent + mdWithoutYaml.substring(indexEndIntroduction);
18+
introductionContent + mdWithoutYaml.trim().substring(indexEndIntroduction);
1919
const chatbotContentLines = chatbotContent.split("\n");
2020
const chatbotData = [];
2121

app/script.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/script.min.js.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)