Fix alternate greetings

This commit is contained in:
Cohee 2023-08-24 11:04:46 +03:00
parent 4aa31fcba9
commit d147bc40dc
1 changed files with 2 additions and 5 deletions

View File

@ -4366,12 +4366,9 @@ function getFirstMessage() {
}; };
if (Array.isArray(alternateGreetings) && alternateGreetings.length > 0) { if (Array.isArray(alternateGreetings) && alternateGreetings.length > 0) {
const swipes = [message.mes, ...(alternateGreetings.map(greeting => substituteParams(getRegexedString(greeting, regex_placement.AI_OUTPUT))))];
message['swipe_id'] = 0; message['swipe_id'] = 0;
message['swipes'] = message['mes'].concat( message['swipes'] = swipes;
alternateGreetings.map(
(greeting) => substituteParams(getRegexedString(greeting, regex_placement.AI_OUTPUT))
)
);
message['swipe_info'] = []; message['swipe_info'] = [];
} }
return message; return message;