feat: support reply to for Telegram (#8105)

Co-authored-by: Muhsin Keloth <muhsinkeramam@gmail.com>
This commit is contained in:
Shivam Mishra
2023-10-20 13:14:20 +05:30
committed by GitHub
parent 7416bbb25e
commit b9694a0818
10 changed files with 146 additions and 12 deletions

View File

@@ -6,6 +6,13 @@ module Telegram::ParamHelpers
params.dig(:message, :chat, :type) == 'private'
end
def telegram_params_content_attributes
reply_to = params.dig(:message, :reply_to_message, :message_id)
return { 'in_reply_to_external_id' => reply_to } if reply_to
{}
end
def message_params?
params[:message].present?
end