summaryrefslogtreecommitdiff
path: root/includes/helper/email_helper.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/helper/email_helper.php')
-rw-r--r--includes/helper/email_helper.php4
1 files changed, 2 insertions, 2 deletions
diff --git a/includes/helper/email_helper.php b/includes/helper/email_helper.php
index 7cd60933..8668cab0 100644
--- a/includes/helper/email_helper.php
+++ b/includes/helper/email_helper.php
@@ -11,9 +11,9 @@ use Engelsystem\Mail\EngelsystemMailer;
*/
function engelsystem_email_to_user($recipient_user, $title, $message, $not_if_its_me = false)
{
- global $user;
+ $user = Auth()->user();
- if ($not_if_its_me && $user['UID'] == $recipient_user['UID']) {
+ if ($not_if_its_me && $user->id == $recipient_user['UID']) {
return true;
}