Use EventEmitter instead of native event handling

This commit is contained in:
maver
2023-06-05 13:21:07 +02:00
parent 4476cbdc81
commit a5e2f11e61
4 changed files with 17 additions and 5 deletions

View File

@@ -7522,6 +7522,7 @@ $(document).ready(function () {
if (popup_type == "del_ch") {
const deleteChats = !!$("#del_char_checkbox").prop("checked");
await handleDeleteCharacter(popup_type, this_chid, deleteChats);
eventSource.emit('characterDeleted', {id: this_chid, character: characters[this_chid]});
}
if (popup_type == "alternate_greeting" && menu_type !== "create") {
createOrEditCharacter();