Merge pull request #2030 from Wolfsblvt/fix-empty-lines-on-group-squash

Fix empty lines on group squashing of char fields
This commit is contained in:
Cohee 2024-04-07 15:37:49 +03:00 committed by GitHub
commit 63117653bb
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 4 additions and 4 deletions

View File

@ -378,10 +378,10 @@ export function getGroupCharacterCards(groupId, characterId) {
mesExamplesArray.push(baseChatReplace(character.mes_example.trim(), name1, character.name));
}
const description = descriptions.join('\n');
const personality = personalities.join('\n');
const scenario = scenarioOverride?.trim() || scenarios.join('\n');
const mesExamples = mesExamplesArray.join('\n');
const description = descriptions.filter(x => x.length).join('\n');
const personality = personalities.filter(x => x.length).join('\n');
const scenario = scenarioOverride?.trim() || scenarios.filter(x => x.length).join('\n');
const mesExamples = mesExamplesArray.filter(x => x.length).join('\n');
return { description, personality, scenario, mesExamples };
}