diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-01 00:09:15 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-04-01 00:09:15 +0300 |
commit | 9c918ae5c688cf492589be0c082956fd72aacea7 (patch) | |
tree | 21b7e3ef09c140c22491f2e583887fc2924c7f16 /app/services/notification_service.rb | |
parent | 676109e1b32682bdbdd94a9ffbd8743784f35521 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/services/notification_service.rb')
-rw-r--r-- | app/services/notification_service.rb | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/services/notification_service.rb b/app/services/notification_service.rb index 26d7bd162df..6e014c0a670 100644 --- a/app/services/notification_service.rb +++ b/app/services/notification_service.rb @@ -79,6 +79,13 @@ class NotificationService mailer.access_token_expired_email(user).deliver_later end + # Notify the user when at least one of their ssh key has expired today + def ssh_key_expired(user, fingerprints) + return unless user.can?(:receive_notifications) + + mailer.ssh_key_expired_email(user, fingerprints).deliver_later + end + # Notify a user when a previously unknown IP or device is used to # sign in to their account def unknown_sign_in(user, ip, time) |