skytnt commited on
Commit
aff3c56
β€’
1 Parent(s): 5d16d44

add download button

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -153,7 +153,7 @@ download_audio_js = """
153
  let audio = root.querySelector("#{audio_id}").querySelector("audio");
154
  if (audio == undefined)
155
  return;
156
- audio = audio.src.replace("audio/wav", "audio/octet-stream");
157
  let oA = document.createElement("a");
158
  oA.download = Math.floor(Math.random()*100000000)+'.wav';
159
  oA.href = audio;
 
153
  let audio = root.querySelector("#{audio_id}").querySelector("audio");
154
  if (audio == undefined)
155
  return;
156
+ audio = audio.src;
157
  let oA = document.createElement("a");
158
  oA.download = Math.floor(Math.random()*100000000)+'.wav';
159
  oA.href = audio;