mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Fix undefined reasoning append on continue
This commit is contained in:
@ -5927,6 +5927,15 @@ export async function saveReply(type, getMessage, fromStreaming, title, swipes,
|
|||||||
chat[chat.length - 1]['extra'] = {};
|
chat[chat.length - 1]['extra'] = {};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Coerce null/undefined to empty string
|
||||||
|
if (!chat[chat.length - 1]['extra']['reasoning']) {
|
||||||
|
chat[chat.length - 1]['extra']['reasoning'] = '';
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!reasoning) {
|
||||||
|
reasoning = '';
|
||||||
|
}
|
||||||
|
|
||||||
let oldMessage = '';
|
let oldMessage = '';
|
||||||
const generationFinished = new Date();
|
const generationFinished = new Date();
|
||||||
const img = extractImageFromMessage(getMessage);
|
const img = extractImageFromMessage(getMessage);
|
||||||
|
Reference in New Issue
Block a user