lunarflu HF Staff commited on
Commit
f3052c3
Β·
1 Parent(s): aee814d

null -> none

Browse files
Files changed (1) hide show
  1. app.py +5 -4
app.py CHANGED
@@ -328,6 +328,7 @@ async def react1234(reaction_emojis, combined_image_dfif):
328
  # Stage 1 βœ…
329
  @bot.command()
330
  async def deepfloydif(ctx, *, prompt: str):
 
331
  try:
332
  try:
333
  if await safetychecks(ctx): #βœ…
@@ -352,7 +353,7 @@ async def deepfloydif(ctx, *, prompt: str):
352
 
353
  except Exception as e:
354
  print(f"Error: {e}")
355
- if thread is Null:
356
  thread = await ctx.message.create_thread(name=f'DFIF1 Error')
357
  await thread.send(f"{ctx.author.mention} Error during stage 1 pre-generation.")
358
  await fullqueue(e, thread)
@@ -376,7 +377,7 @@ async def deepfloydif(ctx, *, prompt: str):
376
 
377
  except Exception as e:
378
  print(f"Error: {e}")
379
- if thread is Null:
380
  thread = await ctx.message.create_thread(name=f'Generation Error')
381
  await thread.send(f"{ctx.author.mention} Error during stage 1 generation.")
382
  await fullqueue(e, thread)
@@ -437,7 +438,7 @@ async def deepfloydif(ctx, *, prompt: str):
437
 
438
  except Exception as e:
439
  print(f"Error: {e}")
440
- if thread is Null:
441
  thread = await ctx.message.create_thread(name=f'Posting Error')
442
  await thread.send(f"{ctx.author.mention} Encountered error while posting combined image in thread.")
443
  await fullqueue(e, thread)
@@ -447,7 +448,7 @@ async def deepfloydif(ctx, *, prompt: str):
447
  #deepfloydif try/except
448
  except Exception as e:
449
  print(f"Error: {e}")
450
- if thread is Null:
451
  thread = await ctx.message.create_thread(name=f'deepfloydif Error')
452
  await thread.send(f"{ctx.author.mention} Overall error with deepfloydif.")
453
  await fullqueue(e, thread)
 
328
  # Stage 1 βœ…
329
  @bot.command()
330
  async def deepfloydif(ctx, *, prompt: str):
331
+ thread = None
332
  try:
333
  try:
334
  if await safetychecks(ctx): #βœ…
 
353
 
354
  except Exception as e:
355
  print(f"Error: {e}")
356
+ if thread is None:
357
  thread = await ctx.message.create_thread(name=f'DFIF1 Error')
358
  await thread.send(f"{ctx.author.mention} Error during stage 1 pre-generation.")
359
  await fullqueue(e, thread)
 
377
 
378
  except Exception as e:
379
  print(f"Error: {e}")
380
+ if thread is None:
381
  thread = await ctx.message.create_thread(name=f'Generation Error')
382
  await thread.send(f"{ctx.author.mention} Error during stage 1 generation.")
383
  await fullqueue(e, thread)
 
438
 
439
  except Exception as e:
440
  print(f"Error: {e}")
441
+ if thread is None:
442
  thread = await ctx.message.create_thread(name=f'Posting Error')
443
  await thread.send(f"{ctx.author.mention} Encountered error while posting combined image in thread.")
444
  await fullqueue(e, thread)
 
448
  #deepfloydif try/except
449
  except Exception as e:
450
  print(f"Error: {e}")
451
+ if thread is None:
452
  thread = await ctx.message.create_thread(name=f'deepfloydif Error')
453
  await thread.send(f"{ctx.author.mention} Overall error with deepfloydif.")
454
  await fullqueue(e, thread)