Merge pull request #205 from Hikari-Haru/conversation-split-message-fix

Fix split messages in conversations breaking conversation
Kaveen Kumarasinghe 2 years ago committed by GitHub
commit 81e57569fe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -426,9 +426,10 @@ class GPT3ComCon(discord.Cog, name="GPT3ComCon"):
first = True
else:
if from_context:
await ctx.send_followup(chunk)
response_message = await ctx.send_followup(chunk)
else:
await ctx.channel.send(chunk)
response_message = await ctx.channel.send(chunk)
return response_message
async def paginate_embed(self, response_text, codex, prompt=None, instruction=None):
"""Given a response text make embed pages and return a list of the pages. Codex makes it a codeblock in the embed"""

@ -432,7 +432,7 @@ class TextService:
if len(response_text) > converser_cog.TEXT_CUTOFF:
if not from_context:
paginator = None
await converser_cog.paginate_and_send(response_text, ctx)
response_message = await converser_cog.paginate_and_send(response_text, ctx)
else:
embed_pages = await converser_cog.paginate_embed(
response_text, codex, prompt, instruction

Loading…
Cancel
Save