FIX: Correctly use invite to topic email templates (#12411)

It was used both when inviting from a topic page and when creating
invites with "Send to topic on first login", while it should be used
only in the former case.
This commit is contained in:
Dan Ungureanu
2021-03-16 17:08:54 +02:00
committed by GitHub
parent bc88ea5976
commit fb19ee9eee
7 changed files with 10 additions and 7 deletions

View File

@ -90,7 +90,7 @@ describe InviteMailer do
Invite.find_by(invited_by_id: topic.user.id)
end
let(:invite_mail) { InviteMailer.send_invite(invite) }
let(:invite_mail) { InviteMailer.send_invite(invite, invite_to_topic: true) }
it 'renders the invitee email' do
expect(invite_mail.to).to eql(['name@example.com'])