debian-mirror-gitlab/app/mailers/repository_check_mailer.rb

16 lines
364 B
Ruby
Raw Normal View History

2016-06-02 11:05:42 +05:30
class RepositoryCheckMailer < BaseMailer
def notify(failed_count)
2017-08-17 22:00:37 +05:30
@message =
if failed_count == 1
"One project failed its last repository check"
else
"#{failed_count} projects failed their last repository check"
end
2016-06-02 11:05:42 +05:30
mail(
to: User.admins.pluck(:email),
subject: "GitLab Admin | #{@message}"
)
end
end