mou3az commited on
Commit
09a5c47
·
verified ·
1 Parent(s): bde77bc

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -0
app.py CHANGED
@@ -47,6 +47,9 @@ def generate_quiz_page():
47
  if request.method == "POST":
48
  context = request.form.get("context")
49
  response = generate_quiz(context)
 
 
 
50
 
51
  quiz_html = f"""
52
  <!DOCTYPE html>
 
47
  if request.method == "POST":
48
  context = request.form.get("context")
49
  response = generate_quiz(context)
50
+
51
+ if "error" in response:
52
+ response = generate_quiz(context)
53
 
54
  quiz_html = f"""
55
  <!DOCTYPE html>