]> _ Git - fluidbook-toolbox.git/commitdiff
wait #7058 @1
authorVincent Vanwaelscappel <vincent@cubedesigners.com>
Mon, 2 Sep 2024 15:28:25 +0000 (17:28 +0200)
committerVincent Vanwaelscappel <vincent@cubedesigners.com>
Mon, 2 Sep 2024 15:28:25 +0000 (17:28 +0200)
app/Models/TeamEmails.php

index b0f9a3f490b88ceff4c9e00c9f8895f098ee157b..c2416aeaaefdfdfd52fd55622b8cdef3ba0a0456 100644 (file)
@@ -209,10 +209,13 @@ class TeamEmails extends CubistMagicAbstractModel
             $emails = array_merge($emails, $company->getEmails());
         }
 
+
         foreach (User::withoutGlobalScopes()->where('created_ok', '1')->where('enabled', '1')->get() as $user) {
+            /** @var User $user */
             $emails = array_merge($emails, $user->getEmails());
         }
 
+        $emails = array_unique($emails);
 
         foreach ($emails as $email) {
             $e = explode('@', $email);