From 5ff3d4eb3a91d1e66d35a919dd38c02b4652e96a Mon Sep 17 00:00:00 2001 From: Chenlei Hu Date: Thu, 27 Jun 2024 09:13:52 -0400 Subject: [PATCH] Fix audio upload when no audio in input dir (#3891) --- web/extensions/core/uploadAudio.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/web/extensions/core/uploadAudio.js b/web/extensions/core/uploadAudio.js index d3dfef4a..12a2a196 100644 --- a/web/extensions/core/uploadAudio.js +++ b/web/extensions/core/uploadAudio.js @@ -145,7 +145,9 @@ app.registerExtension({ ) } // Initially load default audio file to audioUIWidget. - onAudioWidgetUpdate() + if (audioWidget.value) { + onAudioWidgetUpdate() + } audioWidget.callback = onAudioWidgetUpdate const fileInput = document.createElement("input")