TTS: Ignore prompt-hidden messages on auto narration

b7f31cb2ce65e257dae69c1b596f06e8f94a299a

Cohee <18619528+Cohee1207@users.noreply.github.com>

1 files changed, +5 -0Ignore whitespace
public/scripts/extensions/tts/index.js+5 -0
@@ -755,6 +755,11 @@ async function onMessageEvent(messageId, lastCharIndex) {
755755 const message = structuredClone(context.chat[messageId]);
756756 const hashNew = getStringHash(message?.mes ?? '');
757757
758+ // Ignore prompt-hidden messages
759+ if (message.is_system) {
760+ return;
761+ }
762+
758763 // if no new messages, or same message, or same message hash, do nothing
759764 if (hashNew === lastMessageHash) {
760765 return;