mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2024-12-11 17:07:07 +01:00
Add just a chat fields list from server
This commit is contained in:
parent
76c35d269b
commit
671b7ef7cb
@ -7684,6 +7684,8 @@ window['SillyTavern'].getContext = function () {
|
|||||||
setExtensionPrompt: setExtensionPrompt,
|
setExtensionPrompt: setExtensionPrompt,
|
||||||
updateChatMetadata: updateChatMetadata,
|
updateChatMetadata: updateChatMetadata,
|
||||||
saveChat: saveChatConditional,
|
saveChat: saveChatConditional,
|
||||||
|
openCharacterChat: openCharacterChat,
|
||||||
|
openGroupChat: openGroupChat,
|
||||||
saveMetadata: saveMetadata,
|
saveMetadata: saveMetadata,
|
||||||
sendSystemMessage: sendSystemMessage,
|
sendSystemMessage: sendSystemMessage,
|
||||||
activateSendButtons,
|
activateSendButtons,
|
||||||
|
@ -956,6 +956,10 @@ router.post('/chats', jsonParser, async function (request, response) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (request.body.simple) {
|
||||||
|
return response.send(jsonFiles.map(file => ({ file_name: file })));
|
||||||
|
}
|
||||||
|
|
||||||
const jsonFilesPromise = jsonFiles.map((file) => {
|
const jsonFilesPromise = jsonFiles.map((file) => {
|
||||||
return new Promise(async (res) => {
|
return new Promise(async (res) => {
|
||||||
const pathToFile = path.join(request.user.directories.chats, characterDirectory, file);
|
const pathToFile = path.join(request.user.directories.chats, characterDirectory, file);
|
||||||
|
Loading…
Reference in New Issue
Block a user