Chris Addis commited on
Commit
2ea1554
·
1 Parent(s): b13d707

authentication

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -421,12 +421,11 @@ def create_demo():
421
 
422
  return demo
423
 
 
424
  def hello(profile: gr.OAuthProfile | None) -> str:
425
  if profile is None:
426
  return "I don't know you."
427
  return f"Hello {profile.name}"
428
-
429
-
430
 
431
  def create_demo_free():
432
  with gr.Blocks() as demo:
@@ -435,6 +434,7 @@ def create_demo_free():
435
  m2 = gr.Markdown()
436
  m3 = gr.Markdown(f"Authorized User IDs: {', '.join(AUTHORIZED_USER_IDS)}")
437
  demo.load(hello, inputs=None, outputs=m2)
 
438
  return demo
439
 
440
  # Launch the app
 
421
 
422
  return demo
423
 
424
+
425
  def hello(profile: gr.OAuthProfile | None) -> str:
426
  if profile is None:
427
  return "I don't know you."
428
  return f"Hello {profile.name}"
 
 
429
 
430
  def create_demo_free():
431
  with gr.Blocks() as demo:
 
434
  m2 = gr.Markdown()
435
  m3 = gr.Markdown(f"Authorized User IDs: {', '.join(AUTHORIZED_USER_IDS)}")
436
  demo.load(hello, inputs=None, outputs=m2)
437
+ m2 = gr.Markdown(str(check_authorization(None))
438
  return demo
439
 
440
  # Launch the app