Fix race condition duplicates TTS UI if autoload chat enabled
This commit is contained in:
parent
600c9c6251
commit
5b2fff07b8
|
@ -749,10 +749,6 @@ class VoiceMapEntry {
|
|||
*
|
||||
*/
|
||||
export async function initVoiceMap(){
|
||||
// Clear existing voiceMap state
|
||||
$('#tts_voicemap_block').empty()
|
||||
voiceMapEntries = []
|
||||
|
||||
// Gate initialization if not enabled or TTS Provider not ready. Prevents error popups.
|
||||
const enabled = $('#tts_enabled').is(':checked')
|
||||
if (!enabled){
|
||||
|
@ -770,6 +766,10 @@ export async function initVoiceMap(){
|
|||
|
||||
setTtsStatus("TTS Provider Loaded", true)
|
||||
|
||||
// Clear existing voiceMap state
|
||||
$('#tts_voicemap_block').empty()
|
||||
voiceMapEntries = []
|
||||
|
||||
// Get characters in current chat
|
||||
const characters = getCharacters()
|
||||
|
||||
|
|
Loading…
Reference in New Issue