williamagyapong commited on
Commit
e28bfe5
·
verified ·
1 Parent(s): 847d253

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +2 -2
main.py CHANGED
@@ -125,8 +125,8 @@ def process_user_msg(message, mobile):
125
  image_path = os.path.join(response2)
126
  print("My image path:", image_path)
127
  with open(image_path, "rb") as file:
128
- data = file.read()
129
- base64_data = base64.b64encode(data)
130
 
131
  # Upload image to Imgur and get URL
132
  response2 = requests.post(url, headers=headers, data={"image": base64_data})
 
125
  image_path = os.path.join(response2)
126
  print("My image path:", image_path)
127
  with open(image_path, "rb") as file:
128
+ data = file.read()
129
+ base64_data = base64.b64encode(data)
130
 
131
  # Upload image to Imgur and get URL
132
  response2 = requests.post(url, headers=headers, data={"image": base64_data})