Update injector.js

This commit is contained in:
Spicy_Marinara
2026-02-01 13:57:37 +01:00
parent 2a77c091dd
commit b61a426efe
-5
View File
@@ -507,11 +507,6 @@ function onGenerateAfterCombinePrompts(eventData) {
// Always fix newlines around context tags (whether we just injected or not)
eventData.prompt = eventData.prompt.replace(/<context>/g, '\n<context>');
eventData.prompt = eventData.prompt.replace(/<\/context>/g, '</context>\n');
// Remove extra newlines after last_message opening and closing tags
// Match exactly the double newline pattern
eventData.prompt = eventData.prompt.replace(/<last_message>\n\n/g, '<last_message>\n');
eventData.prompt = eventData.prompt.replace(/\n\n<\/last_message>/g, '\n</last_message>');
}
/**