cdleong commited on
Commit
85c5ac2
·
1 Parent(s): 8777b42

Fix quote marks. -_-

Browse files

I blame the people at https://discuss.streamlit.io/t/audio-display/7806 for not formatting their code properly... and myself for copypasting from there instead of https://docs.streamlit.io/library/api-reference/media/st.audio

Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -2,6 +2,6 @@ import streamlit as st
2
 
3
  if __name__ == "__main__":
4
  uploaded_file = st.file_uploader("Choose a file")
5
- with open(uploaded_file, rb) as audio_file:
6
  audio_bytes = audio_file.read()
7
- st.audio(audio_bytes, format=‘audio/wav)
 
2
 
3
  if __name__ == "__main__":
4
  uploaded_file = st.file_uploader("Choose a file")
5
+ with open(uploaded_file, 'rb') as audio_file:
6
  audio_bytes = audio_file.read()
7
+ st.audio(audio_bytes, format='audio/wav')