Welcome mailer not working properly, mail is going every time a user logs in to site


#1

welcome mail is going every time a user logs in to site,i only want it
to
go once when user signed up

app/controllers/user_mailer.rb–

class UserMailer < ActionMailer::Base
default from: “removed_email_address@domain.invalid”
def registration_confirmation(user)

UserMailer.registration_confirmation(@user).deliver
end
end

app/mailers/welcome_mailer.rb–

class WelcomeMailer < ActionMailer::Base
default from: " Impact Institute (alert)
removed_email_address@domain.invalid"

def welcome_confirmation(email)
@email = email
mail(:to => “#{email}”, :subject => “Welcome to
www.impactinstitute.org!”)
end
end