lunarflu HF Staff commited on
Commit
8e0551c
·
1 Parent(s): eb4185e

added with open for f

Browse files
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -103,10 +103,12 @@ async def deepfloydif(ctx, *, prompt: str):
103
 
104
  #3
105
  # Create a public thread based on the sent message
 
106
  thread = await sent_message.create_thread(name='Image Upscaling Thread')
107
 
108
  #4
109
- threadmsg = await thread.send('Here is the combined image. React with the image number you want to upscale!', file=discord.File(f, 'combined_image.png'))
 
110
 
111
  # bot reacts with appropriate emojis to the post, both showing the user what options they have,
112
  # as well as showing which post to react to.
 
103
 
104
  #3
105
  # Create a public thread based on the sent message
106
+ # could replace sent_message with initial user command message? try later
107
  thread = await sent_message.create_thread(name='Image Upscaling Thread')
108
 
109
  #4
110
+ with open(combined_image, 'rb') as f:
111
+ threadmsg = await thread.send('Here is the combined image. React with the image number you want to upscale!', file=discord.File(f, 'combined_image.png'))
112
 
113
  # bot reacts with appropriate emojis to the post, both showing the user what options they have,
114
  # as well as showing which post to react to.