use custom flag instead
| @@ -5301,8 +5301,9 @@ function formatMessageHistoryItem(chatItem, isInstruct, forceOutputSequence) { | ||
| 5301 | 5301 | const itemName = chatItem.is_user ? chatItem['name'] : characterName; |
| 5302 | 5302 | const shouldPrependName = !isNarratorType; |
| 5303 | 5303 | |
| 5304 | - // Don't format messages with undefined content | |
| 5304 | + // If this flag is set, completely ignore the message. | |
| 5305 | - if (chatItem.mes === undefined) { | |
| 5305 | + // This can be used to hide messages without affecting the number of messages in the chat. | |
| 5306 | + if (chatItem.ignore_formatting) { | |
| 5306 | 5307 | return ''; |
| 5307 | 5308 | } |
| 5308 | 5309 | |