fix rubocop

This commit is contained in:
Pranav Raj S 2022-12-21 10:01:51 -08:00
parent 14006e8f31
commit 5ab4906212
4 changed files with 5 additions and 6 deletions

View file

@ -39,7 +39,6 @@ class Api::V1::Widget::MessagesController < Api::V1::Widget::BaseController
Integrations::Dyte::ProcessorService.new(account: @web_widget.inbox.account, conversation: @message) Integrations::Dyte::ProcessorService.new(account: @web_widget.inbox.account, conversation: @message)
end end
def build_attachment def build_attachment
return if params[:message][:attachments].blank? return if params[:message][:attachments].blank?

View file

@ -28,14 +28,14 @@ class Integrations::Dyte::ProcessorService
end end
def add_participant_to_meeting(meeting_id, user) def add_participant_to_meeting(meeting_id, user)
response = dyte_client.add_participant_to_meeting(meeting_id, user.id, user.name, avatar_url(user)) dyte_client.add_participant_to_meeting(meeting_id, user.id, user.name, avatar_url(user))
response
end end
private private
def avatar_url(user) def avatar_url(user)
return user.avatar_url if user.avatar_url.present? return user.avatar_url if user.avatar_url.present?
"#{ENV.fetch('FRONTEND_URL', nil)}/integrations/slack/user.png" "#{ENV.fetch('FRONTEND_URL', nil)}/integrations/slack/user.png"
end end