Skip to content
Snippets Groups Projects
Commit 5646e0b1 authored by Cam Saül's avatar Cam Saül
Browse files

Send email to *all* admins :e-mail:

parent da79fdfe
Branches
Tags
No related merge requests found
......@@ -7,6 +7,7 @@
(stencil [core :as stencil]
[loader :as stencil-loader])
(metabase [config :as config]
[db :as db]
[email :as email])
[metabase.models.setting :as setting]
[metabase.pulse.render :as render]
......@@ -58,9 +59,10 @@
"%s created a Metabase account"
"%s accepted your Metabase invite")
(:common_name new-user))
:recipients [(if google-auth?
(setting/get :admin-email)
(:email invitor))]
:recipients (if google-auth?
(vec (conj (db/select-field :email 'User, :is_superuser true) ; send email to all admins
(setting/get :admin-email)))
[(:email invitor)])
:message-type :html
:message (stencil/render-file "metabase/email/user_joined_notification"
{:logoHeader true
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment