Short formatting path for empty messages
This commit is contained in:
parent
a85a6cf606
commit
4621834c87
|
@ -1474,13 +1474,11 @@ export async function reloadCurrentChat() {
|
||||||
}
|
}
|
||||||
|
|
||||||
function messageFormatting(mes, ch_name, isSystem, isUser) {
|
function messageFormatting(mes, ch_name, isSystem, isUser) {
|
||||||
if (mes) {
|
if (!mes) {
|
||||||
mesForShowdownParse = mes;
|
return '';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!mes) {
|
mesForShowdownParse = mes;
|
||||||
mes = '';
|
|
||||||
}
|
|
||||||
|
|
||||||
// Force isSystem = false on comment messages so they get formatted properly
|
// Force isSystem = false on comment messages so they get formatted properly
|
||||||
if (ch_name === COMMENT_NAME_DEFAULT && isSystem && !isUser) {
|
if (ch_name === COMMENT_NAME_DEFAULT && isSystem && !isUser) {
|
||||||
|
@ -7167,7 +7165,7 @@ window['SillyTavern'].getContext = function () {
|
||||||
/**
|
/**
|
||||||
* @deprecated Handlebars for extensions are no longer supported.
|
* @deprecated Handlebars for extensions are no longer supported.
|
||||||
*/
|
*/
|
||||||
registerHelper: () => {},
|
registerHelper: () => { },
|
||||||
registedDebugFunction: registerDebugFunction,
|
registedDebugFunction: registerDebugFunction,
|
||||||
renderExtensionTemplate: renderExtensionTemplate,
|
renderExtensionTemplate: renderExtensionTemplate,
|
||||||
callPopup: callPopup,
|
callPopup: callPopup,
|
||||||
|
|
Loading…
Reference in New Issue