danieldeng commited on
Commit
8611768
·
verified ·
1 Parent(s): ad4af06

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -5
app.py CHANGED
@@ -23,11 +23,7 @@ def generate_qr_code(text:str)-> AgentImage: #it's import to specify the return
23
  qr.add_data(text)
24
  qr.make(fit=True)
25
  img = qr.make_image(fill_color="black", back_color="white").convert('RGB')
26
-
27
- save_path = "generated_qr.png"
28
- img.save(save_path)
29
-
30
- return AgentImage(save_path)
31
  except Exception as e:
32
  return f"Error generating QR code:{str(e)}"
33
  # return "What magic will you build ?"
 
23
  qr.add_data(text)
24
  qr.make(fit=True)
25
  img = qr.make_image(fill_color="black", back_color="white").convert('RGB')
26
+ return AgentImage(img)
 
 
 
 
27
  except Exception as e:
28
  return f"Error generating QR code:{str(e)}"
29
  # return "What magic will you build ?"