Skip to content

Commit

Permalink
Update MessageService
Browse files Browse the repository at this point in the history
  • Loading branch information
dpS1lence committed Aug 2, 2024
1 parent 7fc68b1 commit 142cd61
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/server/CookingApp/Services/Message/MessageService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -94,15 +94,19 @@ public async Task<MessageData> SendMessage(string userId, MessageData request)
{
saveResponse.Type = MessageType.Recipe;
saveResponse.Content = MessageHelper.RemoveMarkdown(RecipeHelpers.UpdateRecipe(responceText));

await AddTitle(chat.Id, responceText);
}
else
{
saveResponse.Type = MessageType.Text;
saveResponse.Content = responceText;
}

if (request.ChatId == null)
await AddTitle(chat.Id, responceText);

await chatService.UpdateChat(chat.Id, saveRequest, saveResponse);
await AddTitle(chat.Id, responceText);

return new MessageData
{
Expand Down

0 comments on commit 142cd61

Please sign in to comment.