B-K commited on
Commit
bb63f88
·
verified ·
1 Parent(s): 58ff803

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -309,7 +309,8 @@ app = gr.Interface(
309
  outputs=gr.File(label="MIDI File")
310
  )
311
 
312
- if 'google.colab' in str(get_ipython()):
 
313
  app.launch(share=True)
314
- else:
315
  app.launch()
 
309
  outputs=gr.File(label="MIDI File")
310
  )
311
 
312
+ try:
313
+ import google.colab
314
  app.launch(share=True)
315
+ except:
316
  app.launch()