mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-02-13 10:42:55 +01:00
Do not delete selected characters on cancel
This commit is contained in:
parent
581a1e485b
commit
a0f828a2da
@ -528,10 +528,14 @@ class BulkEditOverlay {
|
|||||||
handleContextMenuDelete = () => {
|
handleContextMenuDelete = () => {
|
||||||
callPopup(
|
callPopup(
|
||||||
popupMessage.deleteChat(this.selectedCharacters.length), null)
|
popupMessage.deleteChat(this.selectedCharacters.length), null)
|
||||||
.then(deleteChats =>
|
.then((accept) => {
|
||||||
|
if (true !== accept) return;
|
||||||
|
|
||||||
|
const deleteChats = document.getElementById('del_char_checkbox').checked ?? false;
|
||||||
|
|
||||||
Promise.all(this.selectedCharacters.map(async characterId => CharacterContextMenu.delete(characterId, deleteChats)))
|
Promise.all(this.selectedCharacters.map(async characterId => CharacterContextMenu.delete(characterId, deleteChats)))
|
||||||
.then(() => getCharacters())
|
.then(() => getCharacters())
|
||||||
.then(() => this.browseState())
|
.then(() => this.browseState())}
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user