Update app.py
Browse files
app.py
CHANGED
@@ -2,11 +2,10 @@ import gradio as gr
|
|
2 |
import os
|
3 |
|
4 |
def get_msg(name, request: gr.Request):
|
5 |
-
|
6 |
-
|
7 |
-
if actualorigin == trueorigin:
|
8 |
return "Working"
|
9 |
-
return "Hello " + name + "!" + str(
|
10 |
|
11 |
with gr.Blocks() as demo:
|
12 |
|
|
|
2 |
import os
|
3 |
|
4 |
def get_msg(name, request: gr.Request):
|
5 |
+
header_origin = str(request.headers['origin'])
|
6 |
+
if header_origin == str(os.environ["ORIGIN"]):
|
|
|
7 |
return "Working"
|
8 |
+
return "Hello " + name + "!" + str(header_origin)
|
9 |
|
10 |
with gr.Blocks() as demo:
|
11 |
|